/* ===================================
   TABLE OF CONTENTS
   1. CSS Variables
   2. Font Imports
   3. Reset & Base Styles
   4. Layout & Grid
   5. Header & Navigation
   6. Mobile Navigation
   7. Hero Section
   8. About Section
   9. Services Section
   10. Footer
   11. Form Elements
   12. Animations
   13. Language Selector
   14. Media Queries
=================================== */

/* ===================================
   1. CSS VARIABLES
=================================== */
:root {
  --primary-color: #14002A;
  --text-color: #333;
  --background-color: #fff;
  --shadow-color: rgba(0, 0, 0, 0.1);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --border-radius-sm: 8px;
  --border-radius-md: 20px;
  --border-radius-lg: 30px;
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 2rem;
  --spacing-lg: 4rem;
}

/* ===================================
   2. FONT IMPORTS
=================================== */
@font-face {
  font-family: 'AlteHaasGrotesk';
  src: url('./AlteHaasGroteskRegular.ttf') format('truetype');
  font-weight: normal;
}

@font-face {
  font-family: 'AlteHaasGrotesk';
  src: url('./AlteHaasGroteskBold.ttf') format('truetype');
  font-weight: bold;
  font-weight: 700;
  font-weight: 800;
}

/* ===================================
   3. RESET & BASE STYLES
=================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'AlteHaasGrotesk', sans-serif;
  line-height: 1.6;
  color: var(--text-color);
  font-weight: normal;
}

strong {
  color: var(--primary-color);
  position: relative;
  display: inline-block;
}

strong::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 2px;
  bottom: -2px;
  left: 0;
  background-color: var(--primary-color);
  transform: scaleX(0);
  transition: var(--transition);
  transform-origin: right;
}

strong:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

/* ===================================
   4. LAYOUT & GRID
=================================== */
main {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  margin: 0;
}

footer {
  margin: var(--spacing-md) 0 0;
}

/* ===================================
   5. HEADER & NAVIGATION
=================================== */
.site-header {
  padding: 0.5rem 4rem;
  background-color: var(--background-color);
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.main-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 0 auto;
}

.logo a {
  color: var(--primary-color);
  text-decoration: none;
  font-size: 1.4rem;
  font-weight: 800;
  position: relative;
}

.logo a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -4px;
  left: 0;
  background-color: var(--primary-color);
  transition: var(--transition);
}

.logo a:hover::after {
  width: 100%;
}

.nav-links {
  display: flex;
  list-style: none;
  margin-top: 6px;
  gap: var(--spacing-md);
}

.nav-links a {
  color: var(--text-color);
  text-decoration: none;
  font-size: 0.9rem;
  position: relative;
  font-weight: 500;
  transition: var(--transition);
}

.nav-links a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -4px;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--primary-color);
  transition: var(--transition);
}

.nav-links a:hover::after {
  width: 100%;
}

.business-logo-title {
  display: flex;
  flex-direction: row;
  align-items: center;
}

.business-logo {
  width: auto;
  height: 36px;
  margin-bottom: 6px;
}

.business-title-text {
  font-weight: bold;
  margin-top: 6px;
}

/* ===================================
   6. MOBILE NAVIGATION
=================================== */
.mobile-menu-toggle {
  display: none;
  cursor: pointer;
  z-index: 1010;
  background: none;
  border: none;
  padding: 8px;
}

.hamburger-icon {
  display: block;
  position: relative;
  width: 24px;
  height: 18px;
}

.hamburger-icon span {
  display: block;
  position: absolute;
  height: 2px;
  width: 100%;
  background: var(--primary-color);
  border-radius: 2px;
  opacity: 1;
  left: 0;
  transform: rotate(0deg);
  transition: var(--transition);
}

.hamburger-icon span:nth-child(1) {
  top: 0;
}

.hamburger-icon span:nth-child(2) {
  top: 8px;
}

.hamburger-icon span:nth-child(3) {
  top: 16px;
}

.mobile-menu-toggle.active .hamburger-icon span:nth-child(1) {
  top: 8px;
  transform: rotate(135deg);
}

.mobile-menu-toggle.active .hamburger-icon span:nth-child(2) {
  opacity: 0;
  left: -60px;
}

.mobile-menu-toggle.active .hamburger-icon span:nth-child(3) {
  top: 8px;
  transform: rotate(-135deg);
}

.mobile-nav {
  position: fixed;
  top: 0;
  right: 0;
  width: 80%;
  max-width: 300px;
  height: 100vh;
  background-color: white;
  z-index: 1000;
  box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
  transition: var(--transition);
  display: none; /* Hide by default on desktop */
  flex-direction: column;
  padding: 80px 2rem 2rem;
  overflow-y: auto;
  visibility: hidden;
  transform: translateX(100%);
}

.mobile-nav.active {
  visibility: visible;
  transform: translateX(0);
}

.mobile-nav-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  display: none; /* Hide by default on desktop */
}

.mobile-nav-overlay.active {
  opacity: 1;
  visibility: visible;
}

.mobile-nav-links {
  display: flex;
  flex-direction: column;
  list-style: none;
  padding: 0;
  margin: 0;
}

.mobile-nav-links a {
  color: var(--text-color);
  text-decoration: none;
  font-size: 1.2rem;
  font-weight: 500;
  display: block;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.mobile-nav-links a:hover {
  color: var(--primary-color);
}

.mobile-language-selector {
  display: none; /* Hide by default on desktop */
  align-items: center;
  margin-top: 1rem;
}

.mobile-language-selector .lang-link {
  font-size: 1rem;
  padding: 0.5rem 1rem;
}

/* ===================================
   7. HERO SECTION
=================================== */
.hero {
  padding: 2rem 4rem;
  padding-top: 0;
  position: relative;
  background-color: var(--primary-color);
  color: white;
  transform: translateZ(0);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.hero strong {
  color: white;
  font-weight: bold;
}

.hero strong::after {
  background-color: white;
}

.presentation {
  padding-top: 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  max-width: 80%;
  text-align: center;
}

.presentation-logo {
  height: auto;
  width: 60%;
}

.presentation p {
  margin-top: -2rem;
  font-size: 1.1rem;
  line-height: 1.6;
  max-width: 90%;
}

.subicon-presentation {
  width: 20%;
  height: auto;
  margin-top: 1rem;
}

/* ===================================
   8. ABOUT SECTION
=================================== */
.about-section {
  padding: 3rem 2rem;
  position: relative;
  background: linear-gradient(to right bottom, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.98));
  border-radius: var(--border-radius-lg);
  overflow: hidden;
}

.about-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, rgba(20, 0, 42, 0.03), transparent);
  z-index: 0;
}

.raven-animate {
  position: relative;
  z-index: 2;
  transition: var(--transition);
}

.raven-animate img {
  width: 100%;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 4px 12px rgba(20, 0, 42, 0.15));
  transition: var(--transition);
}

.raven-animate:hover img {
  transform: translateY(-5px) rotate(5deg);
  filter: drop-shadow(0 8px 20px rgba(20, 0, 42, 0.2));
}

.raven-logo {
  width: 100px;
  height: auto;
}

.raven-about {
  transform: scale(-1, 1);
}

.about-content {
  display: flex;
  gap: var(--spacing-lg);
  align-items: center;
}

.about-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1;
  gap: var(--spacing-md);
}

.about-text p {
  font-size: 1.2rem;
  line-height: 1.6;
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
}

.raven-outside-about {
  visibility: hidden;
}

.ghibli-gallery {
  flex: 1;
  display: flex;
  gap: 0;
  align-items: center;
  perspective: 1000px;
  max-height: 80vh;
  min-height: 400px;
  margin-top: -64px;
}

.gallery-image {
  position: relative;
  width: 25%;
  aspect-ratio: 2/6;
  height: 100%;
  overflow: hidden;
  border-radius: 120px;
  transform-style: preserve-3d;
  transition: var(--transition);
  max-width: 408px;
  border: 1px solid var(--primary-color);
}

.gallery-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.gallery-image:hover {
  transform: translateZ(20px);
  z-index: 10;
}

.top-align {
  margin-top: -50px;
}

.bottom-align {
  margin-bottom: -50px;
}

.totoro-shift img {
  object-position: 55% center;
}

.woman-shift img {
  object-position: 60% center;
}

/* ===================================
   9. SERVICES SECTION
=================================== */
.services-section {
  position: relative;
  background: url('passos.svg') center/cover no-repeat;
  overflow: hidden;
  background-attachment: fixed;
  padding: 0 2rem;
}

.services-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.95);
  z-index: 1;
}

.services-header {
  position: relative;
  z-index: 2;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: -24px;
}

.services-header .raven-icon {
  width: 132px;
  height: auto;
  margin-right: -32px;
}

.services-header h2 {
  color: var(--primary-color);
  font-size: 2.5rem;
  font-weight: bold;
}

.services-grid {
  position: relative;
  z-index: 2;
  margin: 0 auto;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: var(--spacing-md);
}

.service-card {
  background: white;
  padding: var(--spacing-md);
  border-radius: var(--border-radius-sm);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
  position: relative;
  transition: var(--transition);
  border: 1px solid rgba(20, 0, 42, 0.1);
  min-width: 18rem;
  max-width: 24rem;
  height: 20rem;
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.card-header h3 {
  color: var(--primary-color);
  font-size: 1.2rem;
  font-weight: bold;
  max-width: 100%;
  text-align: center;
  overflow-wrap: break-word;
  word-wrap: break-word;
  hyphens: auto;
}

.service-card p {
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 2rem;
  flex-grow: 1;
}

.card-line {
  width: 50px;
  height: 2px;
  background-color: var(--primary-color);
  position: absolute;
  bottom: 2rem;
  left: 2rem;
  transition: var(--transition);
}

.service-card:hover .card-line {
  width: 70px;
}

.service-icon-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background-color: #110027;
  border-radius: 20px;
  transition: transform 0.3s ease;
}

.service-icon-wrapper:hover {
  transform: rotate(5deg) scale(1.05);
}

.service-icon-wrapper svg {
  width: 20px;
  height: 20px;
  color: white;
}

.service-icon-wrapper img {
  width: 28px;
  height: 28px;
  filter: brightness(0) invert(1);
}

/* ===================================
   10. FOOTER
=================================== */
.footer {
  background: linear-gradient(to right, var(--primary-color) 50%, #f8f8f8 50%);
  padding: 6rem 0;
  position: relative;
  overflow: hidden;
}

.footer-container {
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-lg);
  padding: 0 var(--spacing-lg);
}

/* Left Section */
.footer-contact {
  color: white;
  padding-right: var(--spacing-lg);
}

.contact-content {
  max-width: 400px;
}

.footer-contact h2 {
  font-size: 3rem;
  font-weight: bold;
  margin-bottom: var(--spacing-md);
  line-height: 1.2;
}

.contact-info {
  margin-bottom: var(--spacing-md);
}

.contact-info p {
  font-size: 1.1rem;
  margin-bottom: 0.8rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.contact-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  opacity: 0.9;
}

.contact-info a {
  color: #ffffff;
  text-decoration: none;
  font-weight: 500;
  transition: var(--transition);
  position: relative;
  display: inline-block;
  padding: 2px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.contact-info a:hover {
  color: #ffffff;
  border-bottom-color: #ffffff;
}

.contact-info a:focus {
  outline: 2px solid #ffffff;
  outline-offset: 4px;
  border-radius: 2px;
}

.contact-info p:hover .contact-icon {
  transform: scale(1.1);
  opacity: 1;
}

.social-links {
  display: flex;
  gap: 1rem;
}

.social-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.social-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.social-icon {
  width: 20px;
  height: 20px;
  fill: white;
}

/* ===================================
   11. FORM ELEMENTS
=================================== */
.footer-form {
  padding-left: var(--spacing-lg);
}

.contact-form {
  background: rgba(255, 255, 255, 0.95);
  padding: 3rem;
  border-radius: var(--border-radius-md);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.form-group {
  margin-bottom: 1rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  background: rgba(0, 0, 0, 0.04);
  border: none;
  border-radius: var(--border-radius-sm);
  font-size: 16px;
  transition: background 0.3s ease;
}

.form-group textarea {
  min-height: 100px;
  resize: vertical;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: #666;
  opacity: 0.8;
}

.form-group input:focus,
.form-group textarea:focus {
  background: rgba(20, 0, 42, 0.06);
  box-shadow: 0 0 0 2px rgba(76, 42, 133, 0.2);
  outline: none;
}

.submit-btn {
  background-color: var(--primary-color);
  color: white;
  padding: 12px 30px;
  border: none;
  border-radius: 25px;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.submit-btn:hover {
  background-color: #1a0040;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(20, 0, 42, 0.3);
}

/* ===================================
   12. ANIMATIONS
=================================== */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-fadeUp {
  animation: fadeUp 0.6s ease-out forwards;
}

/* ===================================
   13. LANGUAGE SELECTOR
=================================== */
.lang-link {
  color: #888;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0 0.5rem;
  transition: var(--transition);
  opacity: 0.7;
  text-align: center;
}

.lang-link.active {
  color: var(--primary-color);
  font-weight: bold;
  opacity: 1;
  position: relative;
}

.lang-divider {
  color: #aaa;
  opacity: 0.4;
  margin: 0 2px;
}

.lang-link:hover {
  color: var(--primary-color);
  opacity: 1;
}

.language-selector {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 4px;
}

/* ===================================
   14. MEDIA QUERIES
=================================== */
/* Large screens */
@media (max-width: 1400px) {
  .raven-inside-about {
    display: none;
  }

  .about-text {
    align-items: unset;
    justify-content: unset;
  }
  
  .raven-outside-about {
    visibility: visible;
  }
  
  .gallery-image {
    border-radius: 80px;
  }
  
  .about-section {
    align-items: flex-start;
  }
}

/* Medium screens */
@media (max-width: 1024px) {
  main {
    gap: var(--spacing-xs);
  }
  
  .hero {
    padding: 0 2rem;
  }
  
  .subicon-presentation {
    margin-top: 0.5rem;
    margin-bottom: 1rem;
  }
  
  .presentation p {
    max-width: 100%;
  }
  
  .about-section {
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
  }

  .about-content {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
  }
  
  .raven-logo {
    width: 80px;
  }

  .ghibli-gallery {
    margin-left: 0;
    margin-top: 3rem;
    height: auto;
    flex-wrap: wrap;
    min-height: unset;
    max-height: unset;
    justify-content: center;
    gap: 0.1rem;
  }

  .gallery-image {
    width: 50%;
    aspect-ratio: 3/4;
    height: auto;
  }

  .top-align, .bottom-align {
    margin-top: 0;
    margin-bottom: 0;
  }
  
  .totoro-shift, .woman-shift img {
    object-position: center;
  }
  
  .service-card:hover {
    transform: translateY(-5px);
  }
  
  .footer {
    background: var(--primary-color);
  }

  .footer-container {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .footer-contact {
    padding-right: 0;
    text-align: center;
  }

  .contact-content {
    margin: 0 auto;
    align-items: center;
    display: flex;
    flex-direction: column;
  }

  .social-links {
    justify-content: center;
  }

  .footer-form {
    padding-left: 0;
  }

  .contact-form {
    margin: 0 auto;
  }
}

/* Tablet screens */
@media (max-width: 900px) {
  .lang-link {
    padding: 0 0.25rem;
  }
}

/* Small screens */
@media (max-width: 880px) {
  .service-card {
    max-width: 100%;
    width: 100%;
    height: auto;
  }
}

@media (max-width: 800px) {
  .presentation-logo {
    width: 90%;
  }
}

/* Mobile screens */
@media (max-width: 768px) {
  main, footer {
    margin: 0;
  }
  
  .presentation p {
    margin-top: -1.5rem;
  }
  
  .about-section {
    padding: 2rem;
    padding-top: 1rem;
  }

  .raven-logo {
    width: 70px;
  }

  .about-text p {
    font-size: 1.1rem;
  }

  .gallery-image {
    width: 100%;
    height: 250px;
  }
  
  .ghibli-gallery {
    justify-content: center;
    max-height: none;
  }

  strong {
    display: unset;
  }
  
  .services-header h2 {
    font-size: 2rem;
  }

  .card-header {
    flex-direction: column-reverse;
    align-items: center;
    text-align: center;
  }

  .card-header h3 {
    font-size: 1.5rem;
    margin-top: 0.5rem;
  }

  .service-icon-wrapper {
    margin-bottom: 0.5rem;
  }
  
  .services-section {
    margin: 1rem;
    padding: 0;
  }
  
  .footer {
    padding: 4rem 0;
  }

  .footer-container {
    padding: 0 2rem;
  }

  .contact-form {
    padding: 2rem;
  }
}

/* Small mobile screens */
@media (max-width: 600px) {
  .nav-links {
    display: none;
  }

  .mobile-menu-toggle {
    display: block;
  }

  .main-nav {
    justify-content: space-between;
  }

  .site-header {
    padding: 0.5rem 1.5rem;
  }
  
  .language-selector {
    display: none;
  }
  
  .language-selector {
    position: absolute;
    top: 0.5rem;
    right: 1rem;
  }
  
  /* Show mobile navigation elements only on mobile */
  .mobile-nav {
    display: flex;
  }
  
  .mobile-nav-overlay {
    display: block;
  }
  
  .mobile-language-selector {
    display: flex;
  }
}

@media (max-width: 580px) {
  .presentation-logo {
    width: 100%;
  }

  .hero {
    padding: 0;
  }
  
  .presentation p {
    margin-top: -1rem;
  }
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}