/* =============================================
   BOOKNANDO -- Design System & Styles
   layout.css -- Container, grids, hero, sections,
   header, mobile nav, footer, logo-scroll, about
   ============================================= */

/* ========================
   Layout
   ======================== */
.container {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding-left: 1rem;
  padding-right: 1rem;
}
@media (min-width: 768px) {
  .container { padding-left: 2rem; padding-right: 2rem; }
}

/* ========================
   Header
   ======================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  transition: all 0.3s;
  background: transparent;
}
.header.scrolled {
  background: hsl(var(--card) / 0.95);
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow-md);
  border-bottom: 1px solid hsl(var(--border));
}
.header .header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem;
}
@media (min-width: 768px) {
  .header .header-inner { padding: 1rem 2rem; }
}
.header .logo img {
  height: 1.5rem;
  width: auto;
  transition: all 0.3s;
}
.header:not(.scrolled) .logo img {
  filter: brightness(0) invert(1);
}
.header nav {
  display: none;
  align-items: center;
  gap: 2rem;
}
@media (min-width: 768px) {
  .header nav { display: flex; }
}
.header nav a {
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 0.2s;
  position: relative;
}
.header nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: hsl(var(--primary));
  transition: width 0.3s;
}
.header nav a:hover::after,
.header nav a.active::after { width: 100%; }
.header:not(.scrolled) nav a {
  color: hsl(0 0% 100% / 0.9);
  text-shadow: 0 1px 3px hsl(0 0% 0% / 0.3);
}
.header:not(.scrolled) nav a:hover {
  color: hsl(0 0% 100%);
}
.header.scrolled nav a {
  color: hsl(var(--muted-foreground));
}
.header.scrolled nav a:hover {
  color: hsl(var(--primary));
}
.header .cta-btn {
  background: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  padding: 0.625rem 1.25rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  transition: background 0.2s;
  box-shadow: var(--shadow-brand);
}
.header .cta-btn:hover {
  background: hsl(var(--brand-dark));
}
.header:not(.scrolled) .cta-btn {
  color: hsl(var(--primary-foreground));
  background: hsl(var(--primary));
}
.header.scrolled .cta-btn {
  color: hsl(var(--primary-foreground));
  background: hsl(var(--primary));
}

/* Mobile menu */
.mobile-toggle {
  display: block;
  padding: 0.5rem;
  background: none;
  border: none;
  cursor: pointer;
  color: hsl(var(--primary-foreground));
}
.header.scrolled .mobile-toggle {
  color: hsl(var(--foreground));
}
@media (min-width: 768px) {
  .mobile-toggle { display: none; }
}
.mobile-nav {
  display: none;
  background: hsl(var(--card));
  border-top: 1px solid hsl(var(--border));
  padding: 1rem;
}
.mobile-nav.open { display: block; }
.mobile-nav a {
  display: block;
  padding: 0.5rem 0;
  font-size: 1rem;
  font-weight: 500;
  color: hsl(var(--foreground));
  transition: color 0.2s;
}
.mobile-nav a:hover { color: hsl(var(--primary)); }
.mobile-nav .cta-btn {
  display: block;
  text-align: center;
  margin-top: 0.5rem;
  padding: 0.75rem;
  border-radius: 0.5rem;
  background: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  font-weight: 600;
  box-shadow: var(--shadow-brand);
  transition: background 0.2s;
}
.mobile-nav .cta-btn:hover {
  background: hsl(var(--brand-dark));
  color: hsl(var(--primary-foreground));
}

/* ========================
   Hero
   ======================== */
.hero {
  position: relative;
  min-height: 70vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero .hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero .hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero .hero-bg .overlay-1 {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(0,0,0,0.85), rgba(0,0,0,0.4), transparent);
}
.hero .hero-bg .overlay-2 {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent, transparent, rgba(0,0,0,0.3));
}
.hero .hero-content {
  position: relative;
  z-index: 10;
  padding: 8rem 1rem;
  max-width: 42rem;
}
@media (min-width: 768px) {
  .hero .hero-content { padding: 8rem 2rem; }
}

/* ========================
   Page Hero (inner pages)
   ======================== */
.page-hero {
  position: relative;
  min-height: 50vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.page-hero .hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.page-hero .hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.page-hero .hero-bg .overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, hsl(var(--navy) / 0.95), hsl(var(--navy) / 0.88), hsl(var(--navy) / 0.70));
}
.page-hero .hero-content {
  position: relative;
  z-index: 10;
  padding: 8rem 1rem;
  max-width: 42rem;
}
@media (min-width: 768px) {
  .page-hero .hero-content { padding: 8rem 2rem; }
}
.page-hero .hero-content h1 {
  color: hsl(0 0% 100%);
  font-family: var(--font-display);
  font-size: 2.25rem;
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 1rem;
}
@media (min-width: 768px) { .page-hero .hero-content h1 { font-size: 2.75rem; } }
.page-hero .hero-content p {
  color: hsl(220 20% 85%);
  font-size: 1.125rem;
  line-height: 1.7;
  max-width: 36rem;
  margin-bottom: 1.5rem;
}
.page-hero .badge {
  display: inline-block;
  background: hsl(var(--primary) / 0.3);
  color: hsl(0 0% 100%);
  border: 1px solid hsl(0 0% 100% / 0.25);
  padding: 0.375rem 1rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

/* ========================
   Sections
   ======================== */
.section {
  padding: 2.5rem 0;
}
@media (min-width: 1024px) {
  .section { padding: 3rem 0; }
}
.section-tag {
  color: hsl(var(--primary));
  font-weight: 600;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.75rem;
}
.section-title {
  font-family: var(--font-display);
  font-size: 1.875rem;
  font-weight: 700;
  color: hsl(var(--foreground));
  margin-bottom: 1rem;
}
@media (min-width: 768px) { .section-title { font-size: 2.25rem; } }
.section-desc {
  color: hsl(var(--muted-foreground));
  font-size: 1.125rem;
  max-width: 42rem;
  margin: 0 auto;
}

/* ========================
   Grid helpers
   ======================== */
.grid { display: grid; gap: 1.5rem; }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr; }
.grid-5 { grid-template-columns: 1fr; }
@media (min-width: 640px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-5 { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 768px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
  .grid-5 { grid-template-columns: repeat(5, 1fr); }
}

/* ========================
   About section
   ======================== */
.about-grid {
  display: grid;
  gap: 4rem;
  align-items: center;
}
@media (min-width: 1024px) {
  .about-grid { grid-template-columns: 1fr 1fr; }
}
.about-image-wrapper {
  position: relative;
}
.about-image-wrapper .main-img {
  aspect-ratio: 1;
  border-radius: 1rem;
  overflow: hidden;
}
.about-image-wrapper .main-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.about-image-wrapper .stat-box {
  position: absolute;
  bottom: -1.5rem;
  left: -1.5rem;
  background: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  padding: 1.5rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-brand);
  max-width: 200px;
}
.about-image-wrapper .stat-box .number {
  font-family: var(--font-display);
  font-size: 1.875rem;
  font-weight: 700;
}
.about-image-wrapper .stat-box .label {
  font-size: 0.875rem;
  opacity: 0.9;
}

/* ========================
   Clients / Logo Scroll
   ======================== */
.logo-scroll-wrapper {
  position: relative;
  overflow: hidden;
}
.logo-scroll-wrapper .fade-left,
.logo-scroll-wrapper .fade-right {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 6rem;
  z-index: 10;
}
.logo-scroll-wrapper .fade-left {
  left: 0;
  background: linear-gradient(to right, hsl(var(--background)), transparent);
}
.logo-scroll-wrapper .fade-right {
  right: 0;
  background: linear-gradient(to left, hsl(var(--background)), transparent);
}
.logo-scroll {
  display: flex;
  animation: logo-scroll 30s linear infinite;
}
.logo-scroll .logo-item {
  flex-shrink: 0;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 5rem;
}
.logo-scroll .logo-item img {
  height: 2.5rem;
  width: auto;
  filter: grayscale(1);
  opacity: 0.6;
  transition: all 0.3s;
}
.logo-scroll .logo-item img:hover {
  filter: grayscale(0);
  opacity: 1;
}

/* ========================
   Contact Grid (página de contato)
   ======================== */
.contact-grid {
  display: grid;
  gap: 2.5rem;
}
@media (min-width: 768px) {
  .contact-grid { grid-template-columns: 1fr 2fr; gap: 3rem; }
}

/* ========================
   Footer
   ======================== */
.footer {
  background: hsl(var(--navy));
  padding: 3rem 0;
}
.footer-grid {
  display: grid;
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}
@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 1fr 1fr 1fr 1fr; }
}
.footer .footer-brand p {
  font-size: 0.875rem;
  line-height: 1.6;
  color: hsl(220 20% 75%);
}
.footer .footer-logo {
  height: 1.5rem;
  width: auto;
  filter: brightness(0) invert(1);
  margin-bottom: 1rem;
}
.footer h3 {
  font-weight: 600;
  margin-bottom: 1rem;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: hsl(0 0% 100%);
}
.footer ul { list-style: none; }
.footer ul li { margin-bottom: 0.5rem; }
.footer ul li a {
  font-size: 0.875rem;
  color: hsl(220 20% 75%);
  transition: color 0.2s;
}
.footer ul li a:hover { text-decoration: underline; }
.footer .contact-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: hsl(220 20% 75%);
}
.footer .lang-links {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
}
.footer .lang-links a {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.375rem 0.75rem;
  border-radius: 0.25rem;
  color: hsl(220 20% 75%);
}
.footer .lang-links a.active {
  background: hsl(var(--primary) / 0.2);
  color: hsl(var(--primary));
}
.footer .footer-bottom {
  border-top: 1px solid hsl(220 30% 25%);
  padding-top: 2rem;
  text-align: center;
  font-size: 0.75rem;
  color: hsl(220 20% 65%);
}
