/* =========================================
   Design System & Tokens
   ========================================= */
:root {
  /* Colors */
  --color-primary: #002147;
  /* Academic Blue (Oxford Blue) */
  --color-accent: #800000;
  /* Distinct Maroon */
  --color-text: #333333;
  /* Dark Charcoal for readability */
  --color-text-light: #666666;
  --color-bg: #FFFFFF;
  --color-bg-alt: #F8F9FA;
  /* Very Light Gray for section separation */
  --color-white: #FFFFFF;

  /* Usage Colors */
  --header-height: 80px;

  /* Shadows & Glassmorphism */
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease-in-out;
}

/* =========================================
   Reset & Base Styles
   ========================================= */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', sans-serif;
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.6;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Playfair Display', serif;
  color: var(--color-primary);
  line-height: 1.25;
  margin-bottom: 1rem;
}

h1 {
  font-size: 3rem;
  font-weight: 700;
}

h2 {
  font-size: 2.25rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 3rem;
  position: relative;
}

h3 {
  font-size: 1.5rem;
  font-weight: 600;
}

p {
  margin-bottom: 1.5rem;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition-fast);
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  display: block;
}

/* =========================================
   Utilities
   ========================================= */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.section-padding {
  padding: 80px 0;
}

.text-center {
  text-align: center;
}

.text-accent {
  color: var(--color-accent);
}

.btn {
  display: inline-block;
  padding: 12px 30px;
  font-weight: 600;
  border-radius: 50px;
  cursor: pointer;
  transition: var(--transition-normal);
  border: 2px solid transparent;
  text-transform: uppercase;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
}

.btn-primary {
  background-color: var(--color-primary);
  color: var(--color-white);
  border: 1px solid var(--color-primary);
}

.btn-primary:hover {
  background-color: #1a3c61;
  /* Lighter Academic Blue */
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: #1a3c61;
}

.btn-outline {
  background-color: transparent;
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.btn-outline:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
}

/* =========================================
   Header & Navigation
   ========================================= */
header {
  position: fixed;
  top: 0;
  width: 100%;
  height: var(--header-height);
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  z-index: 1000;
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.logo {
  display: flex;
  align-items: center;
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--color-primary);
}

.logo img {
  height: 50px;
  /* Adjust based on logo aspect ratio */
  margin-right: 10px;
}

.nav-links {
  display: flex;
  gap: 30px;
}

.nav-links a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--color-primary);
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -4px;
  left: 0;
  background-color: var(--color-accent);
  transition: width 0.3s ease;
}

.nav-links a:hover::after {
  width: 100%;
}

/* =========================================
   Hero Section
   ========================================= */
.hero-btns {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  /* Ensure they wrap gracefully on smaller desktop screens */
  margin-top: 30px;
}

.hero {
  height: 100vh;
  margin-top: var(--header-height);
  /* Avoid overlap implies adjusting hero height calc if desired, or padding */
  padding-top: var(--header-height);
  /* Actually push content down */
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, rgba(0, 33, 71, 0.05) 0%, rgba(255, 255, 255, 0) 70%);
  border-radius: 50%;
  z-index: 0;
}

.hero-content {
  flex: 1;
  z-index: 1;
  padding-right: 50px;
}

.hero-visual {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1;
}

.hero h1 span {
  display: block;
  color: var(--color-accent);
}

.hero-tagline {
  font-size: 1.25rem;
  color: var(--color-text-light);
  margin-bottom: 2.5rem;
  max-width: 600px;
}

/* =========================================
   About Section
   ========================================= */
.about {
  background-color: var(--color-white);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.about-text h2 {
  text-align: left;
}

.stat-card {
  background: var(--color-bg-alt);
  padding: 30px;
  border-radius: 10px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-normal);
}

.stat-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

/* =========================================
   Services Section (Card Design)
   ========================================= */
.services {
  background-color: var(--color-bg-alt);
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.service-card {
  background: var(--color-white);
  padding: 40px 30px;
  border-radius: 12px;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  border-top: 4px solid var(--color-primary);
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-accent);
}

.service-icon {
  font-size: 2.5rem;
  color: var(--color-accent);
  margin-bottom: 20px;
}

.service-icon-img {
  width: 100px;
  height: 100px;
  object-fit: contain;
  margin-bottom: 20px;
}

.service-card h3 {
  margin-bottom: 15px;
}

.service-card p {
  color: var(--color-text-light);
  font-size: 0.95rem;
}

/* =========================================
   Reviews Section (Embedded)
   ========================================= */
.reviews-card {
  background: var(--color-primary);
  color: white;
  padding: 40px;
  border-radius: 12px;
  box-shadow: var(--shadow-md);
  /* Make it span 2 columns on desktop if grid has 3 cols */
  grid-column: span 1;
}

@media (min-width: 992px) {
  .reviews-card {
    grid-column: span 2;
  }
}

.reviews-header {
  margin-bottom: 30px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  padding-bottom: 15px;
}

.reviews-header h3 {
  color: #ffffff;
  margin-bottom: 5px;
}

.testimonial {
  background: rgba(255, 255, 255, 0.1);
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 20px;
  border-left: 4px solid var(--color-accent);
}

.testimonial-text {
  font-style: italic;
  margin-bottom: 10px;
  font-size: 0.95rem;
  line-height: 1.5;
}

.testimonial-author {
  font-size: 0.9rem;
  font-weight: 600;
  color: #ddd;
}

.reviews-form-container {
  background: white;
  padding: 25px;
  border-radius: 8px;
  color: var(--color-text);
  margin-top: 30px;
}

.reviews-form-container h4 {
  color: var(--color-primary);
  margin-bottom: 15px;
}

/* =========================================
   Process Section
   ========================================= */
.process {
  background-color: var(--color-white);
}

.process-steps {
  display: flex;
  flex-direction: column;
  gap: 40px;
  max-width: 900px;
  margin: 0 auto;
}

.process-step {
  display: flex;
  align-items: flex-start;
  gap: 30px;
  padding: 30px;
  background: var(--color-bg-alt);
  border-radius: 12px;
  transition: var(--transition-normal);
  border-left: 5px solid var(--color-primary);
}

.process-step:hover {
  transform: translateX(10px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-accent);
}

.step-number {
  font-family: 'Playfair Display', serif;
  font-size: 3rem;
  font-weight: 700;
  color: var(--color-accent);
  line-height: 1;
  min-width: 60px;
}

.step-content h3 {
  margin-bottom: 10px;
  font-size: 1.4rem;
}

.step-content p {
  margin-bottom: 0;
  color: var(--color-text-light);
}

/* =========================================
   Why Choose Us
   ========================================= */
.features {
  background-color: #f0f4f8;
  /* Light Blue-Gray for separation */
  color: var(--color-text);
  text-align: center;
}

.features h2 {
  color: var(--color-primary);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 30px;
}

.feature-item {
  padding: 20px;
  border-radius: 8px;
  transition: var(--transition-normal);
}

.feature-item:hover {
  background-color: var(--color-white);
  box-shadow: var(--shadow-sm);
  transform: translateY(-5px);
}

.feature-item i {
  font-size: 3rem;
  margin-bottom: 20px;
  color: var(--color-accent);
  background: rgba(128, 0, 0, 0.1);
  width: 80px;
  height: 80px;
  line-height: 80px;
  border-radius: 50%;
  display: inline-block;
}

/* =========================================
   Contact Section
   ========================================= */
.contact {
  background-color: var(--color-white);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: center;
}

@media (max-width: 768px) {
  .contact-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
}

.contact-info {
  /* Center content within the column */
  text-align: center;
}

.contact-info {
  padding: 20px;
}

.contact-form {
  padding: 20px;
  background: var(--color-white);
  border-radius: 8px;
  box-shadow: var(--shadow-md);
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-family: inherit;
  transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-primary);
}

/* =========================================
   Footer
   ========================================= */
footer {
  background-color: #00152e;
  /* Darker than primary */
  color: rgba(255, 255, 255, 0.7);
  padding: 40px 0;
  text-align: center;
}

footer p {
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

/* =========================================
   Mobile Responsiveness
   ========================================= */
.hamburger-menu {
  display: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--color-primary);
}

@media (max-width: 768px) {
  h1 {
    font-size: 2.2rem;
  }

  h2 {
    font-size: 1.8rem;
  }

  header {
    height: 70px;
    padding: 0 20px;
  }

  .nav-container {
    justify-content: space-between;
    height: 100%;
  }

  /* Show Hamburger */
  .hamburger-menu {
    display: block;
  }

  /* Simplify Logo on Mobile */
  .logo span {
    display: none;
    /* Hide "Perismart Editing" text */
  }

  .logo img {
    height: 45px;
  }

  /* Hide Nav by default */
  .nav-links {
    display: none;
    position: absolute;
    top: 70px;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.98);
    flex-direction: column;
    align-items: center;
    padding: 20px 0;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
  }

  /* Show Nav when active */
  .nav-links.active {
    display: flex;
  }

  .nav-links a {
    margin: 10px 0;
    font-size: 1.1rem;
  }

  .hero {
    flex-direction: column;
    height: auto;
    padding-top: 100px;
    padding-bottom: 50px;
    text-align: center;
  }

  .hero-content {
    padding-right: 0;
    margin-bottom: 20px;
  }

  /* Hide decorative logo on mobile - already in header */
  .hero-visual {
    display: none;
  }

  .about-grid,
  .contact-container,
  .hero-btns {
    grid-template-columns: 1fr;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .hero-btns a {
    margin: 20px 0 !important;
    width: 100%;
    max-width: 300px;
  }

  .service-grid,
  .feature-grid {
    grid-template-columns: 1fr;
  }
}