/* CSS Variables for Theming */
:root {
  --bg-color: #f1f5f9; /* Light slate grey background */
  --text-color: #0d121c;
  --text-gray-light: #64748b;
  --text-gray-dark: #334155;
  --panel-bg: #ffffff; /* White panels */
  --glass-bg: rgba(255, 255, 255, 0.5);
  --form-input-bg: #f1f5f9;
  --form-input-border: #cbd5e1;
  --header-icon-color: #0d121c;
  --footer-bg: rgba(255, 255, 255, 0.6);

  /* --- NEW: Accent Color for Borders & Highlights --- */
  --accent-color-light: #cbd5e1; /* slate-300 */
  --accent-color-dark: #94a3b8; /* slate-400 */

  /* Original Accent Colors (for buttons) */
  --accent-color: #000000;
  --accent-text-color: #ffffff;
}

body {
  font-family: 'Poppins', sans-serif;
  background-color: transparent; /*var(--bg-color);*/
  color: var(--text-color);
  cursor: none;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  scroll-behavior: smooth;
  transition: background-color 0.3s ease, color 0.3s ease;
}

body.modal-open {
  overflow: hidden;
}

main {
  padding-top: 2rem;
  padding-bottom: 4rem;
}

#preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--bg-color);
  z-index: 10000;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.5s ease;
}

.loader {
  width: 78px;
  height: calc(27px * 0.866 + 8px);
  background: #000000; /* You can change this color */
  --c1: conic-gradient(from 150deg at top, #000 60deg, #0000 0);
  --c2: conic-gradient(from -30deg at bottom, #000 60deg, #0000 0);
  --s: 27px calc(27px * 0.866);
  clip-path: polygon(18.1px 0, calc(100% - 18.1px) 0, 100% 100%, 0 100%);
  -webkit-mask: var(--c1) left 8px top 50%, var(--c2) center,
    var(--c1) right 8px top 50%, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  -webkit-mask-repeat: no-repeat;
  animation: l3 1.5s infinite;
}

@keyframes l3 {
  0% {
    -webkit-mask-size: 0 0, 0 0, 0 0, auto;
  }
  16.67% {
    -webkit-mask-size: var(--s), 0 0, 0 0, auto;
  }
  33.33% {
    -webkit-mask-size: var(--s), var(--s), 0 0, auto;
  }
  50% {
    -webkit-mask-size: var(--s), var(--s), var(--s), auto;
  }
  66.67% {
    -webkit-mask-size: 0 0, var(--s), var(--s), auto;
  }
  83.33% {
    -webkit-mask-size: 0 0, 0 0, var(--s), auto;
  }
  100% {
    -webkit-mask-size: 0 0, 0 0, 0 0, auto;
  }
}

/* Add these styles for the loader logo */
.loader-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0rem; /* Space between loader and text */
}

.loader-brand-name,
.loader-brand-tagline {
  color: var(--text-color); /* Ensures text color matches the theme */
}

/* Text & Color Variables */
h1,
h2,
h3,
h4,
.section-title,
.service-card h3,
.commitment-card h3,
.work-details h3,
.testimonial-author,
.mobile-link {
  color: var(--text-color);
}
p,
li,
.stat-card p,
.work-details p,
.text-gray-600 {
  color: var(--text-gray-dark);
}
.text-gray-700,
.nav-link,
.mobile-link {
  color: var(--text-gray-dark);
}
.nav-link:hover {
  color: var(--text-color);
}
.text-gray-500 {
  color: var(--text-gray-light);
}

.social-link {
  transition: transform 0.3s ease;
}

.social-link:hover {
  transform: scale(1.1);
}

#header #mobile-menu-btn,
#theme-toggle {
  color: var(--header-icon-color);
}

.commitment-card svg,
.service-card li span {
  color: var(--text-color);
}

/* Split Text Animation */
#hero-title {
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
}

#hero-title .char {
  display: inline-block;
  transform: translateY(100%);
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

#global-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  opacity: 0.5;
}

#global-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  opacity: 0.5;
}
.hero-content {
  position: relative;
  z-index: 1;
}

.gradient-text {
  background: linear-gradient(
    90deg,
    var(--text-color) 20%,
    #9ca3af 50%,
    var(--text-color) 80%
  );
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  background-size: 200% auto;
  animation: gradient-animation 4s linear infinite;
}

@keyframes gradient-animation {
  to {
    background-position: 200% center;
  }
}

.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid var(--glass-border);
  border-radius: 1rem;
  transition: all 0.3s ease;
}
.glass-card:hover {
  background: rgba(0, 0, 0, 0.05);
  border-color: rgba(0, 0, 0, 0.15);
  transform: translateY(-8px);
  box-shadow: 0 20px 30px rgba(0, 0, 0, 0.08);
}
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--form-input-bg);
}
::-webkit-scrollbar-thumb {
  background: var(--text-gray-light); /* Changed from yellow */
  border-radius: 4px;
}

/* style.css */

#process-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease;
  border-radius: 2rem; /* Match the panel's border-radius */
}

.tech-scroller {
  width: 100%;
  overflow: hidden;
  padding: 0 0;
  -webkit-mask-image: linear-gradient(
    to right,
    transparent,
    rgb(102, 99, 99) 1%,
    rgb(109, 107, 107) 99%,
    transparent
  );
  mask-image: linear-gradient(
    to right,
    transparent,
    rgb(124, 122, 122) 1%,
    rgb(104, 102, 102) 99%,
    transparent
  );
}

.tech-scroller .scroller-inner {
  display: flex;
  gap: 2.5rem;
  width: max-content;
}

/* Styling for the tech logo images */
.tech-scroller {
  width: 100%;
  overflow: hidden;
  padding: 2rem 0;
  background-color: var(--form-input-bg); /* Added grey background */
  -webkit-mask-image: linear-gradient(
    to right,
    transparent,
    white 10%,
    white 90%,
    transparent
  );
  mask-image: linear-gradient(
    to right,
    transparent,
    white 10%,
    white 90%,
    transparent
  );
}

.tech-scroller .scroller-inner {
  display: flex;
  gap: 2.5rem;
  width: max-content;
}

/* Styling for the tech logo images */
.tech-scroller img {
  height: 45px; /* Restored original height */
  opacity: 0.8;
  transition: all 0.3s ease-in-out;
}

/* Reverted tech-item to a simple container */
.tech-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  width: 90px;
  text-align: center;
}

.tech-item span {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-gray-dark);
  white-space: nowrap;
}

/* Restored original hover effect on the image itself */
.tech-scroller img:hover {
  opacity: 1;
  transform: scale(1.15);
}

.magnetic-btn {
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: inline-block;
  vertical-align: middle;
}

.magnetic-btn span {
  display: inline-block;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* --- New Solid Pointer Cursor --- */
.custom-cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 20px;
  height: 20px;
  border: 2px solid var(--text-color);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transition: transform 0.2s ease-out, width 0.3s ease, height 0.3s ease,
    background-color 0.3s ease, border-color 0.3s ease;
  transform: translate(-50%, -50%);
  background-color: rgba(128, 128, 128, 0.1);
  will-change: transform, width, height, background-color, border-color;
}
.custom-cursor.hovered {
  width: 50px;
  height: 50px;
  background-color: rgba(128, 128, 128, 0.2);
  border-color: var(--text-color); /* Changed from yellow */
}

/* In style.css */

/* 1. MAKE THE MAIN PANEL WRAPPER TRANSPARENT */
.panel {
  background-color: var(--panel-bg); /* RESTORED */
  position: relative;
  z-index: 1;
  padding: 4rem 0 2rem 0;
  box-shadow: inset 0 0 100px rgba(0, 0, 0, 0.02); /* RESTORED */
  transition: background-color 0.3s ease;
  border-radius: 2rem; /* RESTORED */
  margin: 0 2.5rem 2rem 2.5rem;
  border: 1px solid transparent; /* Required for the shiny border */
}

/* Remove the shining border from the now-invisible panel */
.panel::before {
  display: block; /* RESTORED */
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    120deg,
    var(--accent-color-light),
    var(--accent-color-dark),
    var(--accent-color-light)
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  z-index: 3;
}

.footer-bg {
  position: relative; /* Needed to contain the ::before pseudo-element */
  z-index: 0; /* Creates a stacking context */
  background-color: var(--footer-bg);

  /* --- Add these lines for the blur effect --- */
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(10px);
}

/* --- Add this new rule for the noise effect --- */
.footer-bg::before {
  content: '';
  position: absolute;
  inset: 0; /* Covers the entire footer area */
  z-index: -1; /* Sits behind the footer content but over the background */

  /* This is the same noise texture from your old background effect */
  background-image: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIzMDAiIGhlaWdodD0iMzAwIj48ZmlsdGVyIGlkPSJzIiB4PSIwIiB5PSIwIj48ZmVUdXJidWxlbmNlIHR5cGU9ImZyYWN0YWxOb2lzZSIgYmFzZUZyZXF1ZW5jeT0iMS45IiBudW1PY3RhdmVzPSIzIiBzdGl0Y2hUaWxlcz0ic3RpdGNoIi8+PC9maWx0ZXI+PHJlY3Qgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgZmlsdGVyPSJ1cmwoI3MpIiBvcGFjaXR5PSIwLjA1Ii8+PC9zdmc+');

  pointer-events: none; /* Ensures the noise layer doesn't block mouse clicks */
}

#process .max-w-4xl::before {
  content: '';
  position: absolute;
  left: 10px;
  transform: none;
  width: 3px;
  background-color: rgba(128, 128, 128, 0.2);
  z-index: 0;
  border-radius: 2px;
}

#process .max-w-4xl::after {
  content: '';
  display: table;
  clear: both;
}

.timeline-progress {
  position: absolute;
  left: 10px;
  transform: translateX(-50%);
  width: 3px;
  background: var(--accent-color); /* Changed from yellow */
  z-index: 0;
  border-radius: 2px;
  height: 0;
}

.process-step {
  position: relative;
  width: 100%;
  text-align: left;
  padding-left: 40px;
  margin-bottom: 3rem;
}

.process-step::before {
  content: '';
  position: absolute;
  top: 0;
  left: 10px;
  transform: translateX(-50%);
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background-color: var(--form-input-bg);
  border: 4px solid var(--panel-bg);
  z-index: 2;
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.process-step.is-active::before {
  background-color: var(--accent-color); /* Changed from yellow */
}

/* Client Logos */
.client-logo {
  display: flex;
  justify-content: center;
}
.client-logo img {
  opacity: 0.5;
  filter: grayscale(100%);
  transition: all 0.3s ease;
}
.client-logo img:hover {
  opacity: 1;
  filter: grayscale(0%);
}

/* Portfolio Filter Buttons */
.filter-btn {
  padding: 0.5rem 1.5rem;
  border-radius: 9999px;
  font-weight: 500;
  transition: all 0.3s ease;
  border: 1px solid var(--panel-border);
  color: var(--text-gray-dark);
}

.filter-btn:hover {
  color: var(--text-color);
  background-color: var(--glass-bg);
  border-color: var(--glass-border);
}

.filter-btn.active {
  background-color: var(--accent-color); /* Changed from yellow */
  color: var(--accent-text-color); /* Changed from yellow */
  border-color: var(--accent-color); /* Changed from yellow */
}

/* NEW: Work Section Polaroid Grid */
#work-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.work-item {
  background-color: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-radius: 0.75rem;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease-in-out;
  z-index: 1;
}

.work-item:hover {
  transform: translateY(-10px) rotate(2deg) scale(1.05);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  z-index: 10;
}

/* Add some variety to the rotation */
.work-item:nth-child(2n) {
  transform: rotate(-2deg);
}

.work-item:nth-child(2n):hover {
  transform: translateY(-10px) rotate(-2deg) scale(1.05);
}

.work-item .work-image {
  border-top-left-radius: 0.75rem;
  border-top-right-radius: 0.75rem;
  overflow: hidden;
}

.work-item .work-image img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.work-item:hover .work-image img {
  transform: scale(1.1);
}

.work-item .work-details {
  padding: 1.25rem;
}

/* FAQ Accordion */
.faq-item {
  background-color: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 0.75rem;
  overflow: hidden;
}

.faq-question {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.25rem;
  text-align: left;
  font-weight: 600;
  color: var(--text-color);
}

.faq-icon {
  width: 1.5rem;
  height: 1.5rem;
  transition: transform 0.3s ease;
}

.faq-item.active .faq-icon {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease-out;
  padding: 0 1.25rem;
  color: var(--text-gray-dark);
}
.faq-answer p {
  padding-bottom: 1.25rem;
}

/* Form Inputs */
.form-input {
  width: 100%;
  margin-top: 0.5rem;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  background-color: var(--form-input-bg);
  border: 1px solid var(--form-input-border);
  transition: all 0.3s ease;
  color: var(--text-color);
}
.form-input:focus {
  border-color: var(--accent-color-dark);
  background-color: var(--bg-color);
  outline: none;
  box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.3); /* Soft slate glow */
  ring: 0;
}

/* ADD THESE STYLES FOR REAL-TIME VALIDATION */
.form-input.is-valid {
  border-color: #22c55e; /* green-500 */
}
.form-input.is-valid:focus {
  border-color: #22c55e;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.3);
}

.form-input.is-invalid {
  border-color: #ef4444; /* red-500 */
}
.form-input.is-invalid:focus {
  border-color: #ef4444;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.3);
}

/* Primary CTA Buttons */
.btn-monochrome {
  background-color: var(--accent-color);
  color: var(--accent-text-color);
}

/* Case Study Modals */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 100;
  display: none; /* Initially hidden */
  align-items: center;
  justify-content: center;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal.active {
  opacity: 1;
}

.modal-content {
  background-color: var(--panel-bg);
  padding: 2rem;
  border-radius: 1rem;
  max-width: 56rem; /* max-w-5xl */
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.modal.active .modal-content {
  transform: scale(1);
}

.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 2rem;
  font-weight: bold;
  color: var(--text-gray-light);
  cursor: pointer;
  background: none;
  border: none;
}
.modal-close:hover {
  color: var(--text-color);
}

/* Cookie Banner */
.cookie-banner {
  position: fixed;
  bottom: -100%;
  left: 0;
  right: 0;
  background-color: var(--panel-bg);
  padding: 1rem 1.5rem;
  z-index: 200;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: bottom 0.5s ease-in-out;
}

.cookie-banner.active {
  bottom: 0;
}

.cookie-banner p {
  margin: 0;
  color: var(--text-gray-dark);
}

.cookie-banner a {
  color: var(--text-color);
}

.cookie-button {
  background-color: var(--accent-color); /* Changed from yellow */
  color: var(--accent-text-color); /* Changed from yellow */
  border: none;
  padding: 0.5rem 1.5rem;
  border-radius: 9999px;
  font-weight: 500;
  margin-left: 1.5rem;
  cursor: pointer;
}

/* --- Floating Chatbot --- */
.chatbot-toggle-btn {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 90px;
  height: 90px;
  background-color: transparent;
  color: var(--accent-text-color);
  border-radius: 50%;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 998;
  /*transition: transform 0.3s ease, background-color 0.3s ease;*/
  transition: transform 0.3s ease, opacity 0.3s ease, visibility 0.3s ease;
}

/* In style.css, add this new rule */
body.cookie-banner-is-active #chatbot-toggle-btn,
body.footer-is-visible #chatbot-toggle-btn {
  opacity: 0;
  visibility: hidden;
  transform: scale(0.8);
  pointer-events: none; /* Prevents clicks when hidden */
}

.chatbot-toggle-btn img {
  width: 100%;
  height: 100%;
}

.chatbot-toggle-btn:hover {
  transform: scale(1.1);
}

.chatbot-modal {
  position: fixed;
  bottom: 6.5rem;
  right: 2rem;
  width: 90%;
  max-width: 380px;
  height: 70vh;
  max-height: 500px;
  background-color: var(--panel-bg);
  border-radius: 1rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  z-index: 999;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
  border: 1px solid var(--panel-border);
}

.chatbot-modal.active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.chatbot-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--panel-border);
  color: var(--text-color);
}
.chatbot-header .modal-close {
  position: static;
  font-size: 1.5rem;
}

.chatbot-body {
  flex-grow: 1;
  padding: 1rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.chat-message {
  padding: 0.65rem 1rem;
  border-radius: 1rem;
  max-width: 85%;
  line-height: 1.5;
}
.chat-message p {
  margin: 0;
}

.chat-message.bot {
  background-color: var(--form-input-bg);
  color: var(--text-gray-dark);
  border-bottom-left-radius: 0.25rem;
  align-self: flex-start;
}

.chat-message.user {
  background-color: var(--accent-color);
  color: var(--accent-text-color);
  border-bottom-right-radius: 0.25rem;
  align-self: flex-end;
}

.chatbot-footer {
  display: flex;
  gap: 0.5rem;
  padding: 0.75rem;
  border-top: 1px solid var(--panel-border);
}

.chatbot-footer .form-input {
  margin-top: 0;
}

#chatbot-send-btn {
  flex-shrink: 0;
}

@media (min-width: 768px) {
  #process .max-w-4xl::before,
  .timeline-progress {
    left: 50%;
    transform: translateX(-50%);
  }
  .process-step {
    width: 50%;
    padding-left: 0;
    margin-bottom: 4rem;
  }
  .process-step:nth-of-type(odd) {
    float: left;
    clear: both;
    text-align: right;
    padding-right: 40px;
  }
  .process-step:nth-of-type(odd)::before {
    left: 100%;
  }
  .process-step:nth-of-type(even) {
    float: right;
    clear: both;
    text-align: left;
    padding-left: 40px;
  }
  .process-step:nth-of-type(even)::before {
    left: 0;
  }
}

#header.header-scrolled {
  background-color: var(--glass-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

#header.header-scrolled {
  border-bottom: 1px solid var(--glass-border);
}

/* --- Shining Gradient Border Effect --- */

/* 1. Prepare elements for gradient border */
.panel,
.glass-card,
.work-item,
.faq-item,
.filter-btn,
.service-hover-wrap {
  position: relative; /* Required for the pseudo-element */
  border: 1px solid transparent; /* Fallback and layout spacing */
}

/* 2. Create the gradient pseudo-element */
.panel::before,
.glass-card::before,
.work-item::before,
.faq-item::before,
.filter-btn::before,
.service-hover-wrap::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit; /* Matches the parent's border-radius */
  padding: 1px; /* The width of the border */
  background: linear-gradient(
    120deg,
    var(--accent-color-light),
    var(--accent-color-dark),
    var(--accent-color-light)
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none; /* Allows clicks to go through to the element */
  z-index: 3;
}

/* 3. Style active filter button with new accent */
.filter-btn.active {
  background-color: var(--accent-color-dark);
  color: #fff;
}
.filter-btn.active::before {
  background: none; /* Hide gradient when active */
}

/* --- Animated Underline for Header Nav Links --- */
.nav-link {
  position: relative; /* This is necessary to position the underline */
  text-decoration: none; /* Removes any default browser underline */
  padding-bottom: 6px; /* Adds a little space for the underline to appear */
}

.nav-link::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 2px;
  bottom: 0;
  left: 0;
  background-color: var(--text-color); /* The color of the underline */
  transform: scaleX(0);
  transform-origin: bottom left;
  transition: transform 0.3s ease-out;
}

/* On hover, scale the underline to its full width */
.nav-link:hover::after {
  transform: scaleX(1);
  transform-origin: bottom left;
}

.about-image-container {
  max-width: 80%;
  margin: 0 auto;
}

/* --- New Work Showcase Section --- */
.work-showcase-grid {
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  gap: 2rem;
  min-height: 450px;
}

@media (min-width: 1024px) {
  .work-showcase-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 4rem;
  }
}

.work-card-carousel {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 400px;
  /* Perspective is CRUCIAL for the 3D effect */
  perspective: 1500px;
}

.work-card-stack {
  position: relative;
  width: 300px;
  height: 189px;
  /* This enables 3D positioning for child elements */
  transform-style: preserve-3d;
}

.showcase-card {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 1rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  overflow: hidden;
  transform-origin: center;
  transition: transform 0.7s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.7s ease;
  cursor: pointer;
  background-color: var(
    --panel-bg
  ); /* Add a background for the image to sit on */
}

.showcase-card img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* CENTER/ACTIVE CARD */
.showcase-card.active {
  transform: translateX(0) translateY(0) translateZ(0) rotateY(0) scale(1.1);
  z-index: 10;
  opacity: 1;
}

/* CARDS IMMEDIATELY NEXT TO ACTIVE */
.showcase-card.prev {
  transform: translateX(-50%) translateY(-20%) translateZ(-150px) rotateY(30deg)
    scale(0.95);
  z-index: 5;
  opacity: 0.7;
}

.showcase-card.next {
  transform: translateX(50%) translateY(-20%) translateZ(-150px) rotateY(-30deg)
    scale(0.95);
  z-index: 5;
  opacity: 0.7;
}

/* FADED CARDS IN THE BACKGROUND */
.showcase-card.hidden-prev {
  transform: translateX(-70%) translateY(-35%) translateZ(-300px) rotateY(45deg)
    scale(0.8);
  z-index: 1;
  opacity: 0.4;
}

.showcase-card.hidden-next {
  transform: translateX(70%) translateY(-35%) translateZ(-300px) rotateY(-45deg)
    scale(0.8);
  z-index: 1;
  opacity: 0.4;
}

/* --- Navigation and Details Pane (No Changes) --- */
.work-carousel-nav {
  position: absolute;
  right: -2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.work-carousel-nav button {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-color);
  transition: all 0.2s ease;
}

.work-carousel-nav button:hover {
  background: var(--accent-color-light);
  transform: scale(1.1);
}

.work-details-pane {
  position: relative;
  padding: 1rem;
}

.work-description {
  display: none;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.work-description.active {
  display: block;
  opacity: 1;
  transform: translateY(0);
}

/* --- New Testimonial Flip Section Styles --- */
.testimonial-flipper {
  max-width: 48rem; /* max-w-3xl */
  margin: 0 auto;
  position: relative;
  min-height: 300px; /* Adjust as needed */
  perspective: 1000px; /* Crucial for 3D effect */
}

.testimonial-card {
  position: absolute;
  width: 100%;
  text-align: center;
  opacity: 100;
  transform: rotateY(-90deg);
  transition: transform 0.6s ease-in-out, opacity 0.6s ease-in-out;
  backface-visibility: hidden; /* Prevents flickering during flip */
}

.testimonial-card.active {
  opacity: 100;
  transform: rotateY(0deg);
}

.testimonial-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: var(--accent-color-light);
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.testimonial-dot.active {
  background-color: var(--accent-color-dark);
}

/* --- AI-Powered Build Section --- */
.ai-video-container {
  border-radius: 1.5rem; /* 24px */
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  aspect-ratio: 16 / 10;
  position: relative;
  border: 1px solid transparent; /* Required for gradient border */
}

.ai-tool-logo {
  display: flex;
  flex-direction: column; /* Lays out items vertically */
  align-items: center; /* Centers items horizontally */
  gap: 0.5rem; /* Adds space between logo and name */
  width: 90px; /* Gives each item a fixed width */
  text-align: center; /* Ensures text is centered */
  background-color: transparent; /* Makes the individual item background transparent */
}

.ai-tool-logo:hover {
  transform: scale(1.1) translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.08);
  background-color: var(--panel-bg);
}

.ai-tool-logo img {
  height: 40px;
  width: 40px;
  object-fit: contain;
  opacity: 0.7;
  transition: opacity 0.3s ease;
}

.ai-tool-logo:hover img {
  opacity: 1;
}

/* Add shining border effect to the video container */
.ai-video-container {
  border: 1px solid transparent;
}
.ai-video-container::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    120deg,
    var(--accent-color-light),
    var(--accent-color-dark),
    var(--accent-color-light)
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

/* Hide scrollbar for Chrome, Safari and Opera */
body::-webkit-scrollbar {
  display: none;
}

/* PASTE THIS AT THE END OF style.css (after removing the old service styles) */

/* --- New Service Card Hover Effect Styles --- */
.service-hover-wrap {
  display: flex;
  width: 100%;
  height: 300px; /* Give the card a fixed height */
  border: 5px solid transparent; /* Required for gradient border */
  transition: 0.3s ease-in-out; /* Smooth transition for hover effects */
  position: relative; /* Needed for absolute positioning of children */
  overflow: hidden; /* Ensures content doesn't overflow the card */
  border-radius: 1.5rem; /* 24px */

  background: var(--glass-bg); /* Use the semi-transparent background */
  backdrop-filter: blur(15px); /* Add the blur effect */
  -webkit-backdrop-filter: blur(15px); /* For Safari browser support */
}

.service-hover-wrap .overlay {
  position: relative; /* Changed from absolute to relative */
  display: flex; /* Use flexbox for layout */
  width: 100%; /* Full width */
  height: 100%; /* Full height */
  padding: 1rem; /* Padding inside the overlay */
  background: transparent; /* Dark overlay background */
  transition: 0.4s ease-in-out; /* Smooth transition for hover effects */
  z-index: 2; /* Sits above the image */
}

.service-hover-wrap .overlay-content {
  display: flex; /* Use flexbox for layout */
  flex-direction: column; /* Stack items vertically */
  justify-content: space-between; /* Space out items */
  width: 34%; /* Adjust width of the side content */
  height: 150%; /* Full height */
  padding: 1 0rem; /* Padding inside the side content */
  /*border-right: 4px solid #333; Separator line */
  transition: 0.3s ease-in-out 0.2s; /* Delay for smooth transition */
  z-index: 1; /* Sits below the overlay */
  border-right: 3px solid;
  border-image-source: linear-gradient(
    to bottom,
    var(--accent-color-light),
    var(--accent-color-dark)
  );
  border-image-slice: 1;
}

/* --- Add this for the smooth text reveal on service cards --- */

/* 1. Set the initial (hidden) state of the text */
.service-hover-wrap .text {
  opacity: 0; /* Start fully transparent */
  transform: translateX(20px); /* Start slightly to the right */
  transition: opacity 0.4s ease-out 0.1s, transform 0.1s ease-out 0.1s; /* Animate the change with a slight delay */
}

/* 2. Set the final (visible) state when hovering */
.service-hover-wrap:hover .text {
  opacity: 1; /* Fade in to be fully visible */
  transform: translateX(0); /* Slide back to its original position */
}

.service-hover-wrap .overlay-content h1 {
  font-size: 1.5rem; /* 36px */
  font-weight: 700; /* Bold font */
  text-align: left; /* Align text to the left */
  color: white; /* White text for contrast */
}

.service-hover-wrap .overlay-content p {
  font-size: 1rem; /* 16px */
  color: #9ca3af; /* gray-400 */
}

.service-hover-wrap .image-content {
  position: absolute;
  top: 0; /* Sticks to the top */
  right: 0; /* Sticks to the right */
  width: 65%; /* The rest of the width */
  height: 100%; /* Full height */
  background-size: cover; /* Ensures the image covers the area */
  background-position: center center; /* Centers the image */
  transition: 0.3s ease-in-out; /* Smooth transition for hover effects */
}

.service-hover-wrap .dots {
  position: absolute;
  bottom: 1rem;
  right: 1.5rem;
  display: flex;
  gap: 0.5rem;
  transition: 0.3s ease-in-out 0.3s;
}

.service-hover-wrap .dot {
  width: 0.75rem; /* 12px */
  height: 0.75rem; /* 12px */
  background: white;
  border-radius: 50%;
  transition: 0.3s ease-in-out 0.3s;
}

.service-hover-wrap .text {
  position: absolute; /* Positioned absolutely */
  top: 0; /* Sticks to the top */
  right: 0; /* Sticks to the right */
  width: 75%; /* Match the initial image width */
  height: 100%; /* Full height */
  padding: 1rem 1rem 1rem 2rem; /* Padding inside the text area */
  background: var(--panel-bg); /* Background color for text area */
  overflow-y: auto; /* Enables vertical scrolling if content overflows */
  z-index: 1; /* Sits below the overlay */
}

.service-hover-wrap .overlay h1 {
  color: #0d121c; /* Dark text for contrast */
}

.service-hover-wrap .text h3 {
  font-size: 1rem; /* 24px */
  font-weight: 700; /* Bold font */
  margin-bottom: 1rem; /* Space below the heading */
  color: var(--text-color); /* Use the main text color */
}

.service-hover-wrap .text p {
  color: var(--text-gray-dark); /* Dark gray text for readability */
  margin-bottom: 1.5rem; /* Space below paragraphs */
}

.service-hover-wrap .text ul {
  list-style: none; /* Removes default list styling */
  padding: 0; /* Removes default padding */
}

/* --- THE HOVER EFFECT --- */
.service-hover-wrap:hover .overlay {
  transform: translateX(-70%); /* Slides the overlay to reveal the text */
}

.service-hover-wrap:hover .image-content {
  width: 30%; /* Shrinks the image to the side */
}

.service-hover-wrap:hover .overlay-content,
.service-hover-wrap:hover .dots {
  opacity: 0;
  transition: opacity 0.2s ease-in-out;
}

.service-hover-wrap:hover .overlay-content {
  border: none; /* Removes the separator line */
  transition-delay: 0.2s; /* Delay to sync with overlay movement */
  transform: translateX(
    calc(100% / 0.35)
  ); /* Pushes the side content off-screen */
}

/* --- Animations and timing delays --- */
.animate {
  animation-duration: 0.7s; /* Duration of the animation */
  animation-timing-function: cubic-bezier(
    0.26,
    0.53,
    0.74,
    1.48
  ); /* Spring-like easing */
  animation-fill-mode: backwards; /* Ensures the element is hidden before animation starts */
}
.pop {
  animation-name: pop;
}
@keyframes pop {
  0% {
    opacity: 0;
    transform: scale(0.5, 0.5);
  }
  100% {
    opacity: 1;
    transform: scale(1, 1);
  }
}
.slide {
  animation-name: slide;
}
@keyframes slide {
  0% {
    opacity: 0;
    transform: translate(4em, 0);
  }
  100% {
    opacity: 1;
    transform: translate(0, 0);
  }
}
.slide-left {
  animation-name: slide-left;
}
@keyframes slide-left {
  0% {
    opacity: 0;
    transform: translate(-40px, 0);
  }
  100% {
    opacity: 1;
    transform: translate(0, 0);
  }
}
.slide-up {
  animation-name: slide-up;
}
@keyframes slide-up {
  0% {
    opacity: 0;
    transform: translateY(3em);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}
.delay-2 {
  animation-delay: 0.6s;
}
.delay-4 {
  animation-delay: 1.2s;
}
.delay-5 {
  animation-delay: 1.5s;
}
.delay-6 {
  animation-delay: 1.8s;
}
.delay-7 {
  animation-delay: 2.1s;
}
.delay-8 {
  animation-delay: 2.4s;
}

/* --- Hide Scrollbar in Service Cards --- */
.service-hover-wrap .text {
  scrollbar-width: none; /* For Firefox */
}

.service-hover-wrap .text::-webkit-scrollbar {
  display: none; /* For Chrome, Safari, and Opera */
}

/* --- Dropdown Menu Styles --- */

/* The container for the dropdown link and menu */
.dropdown-container {
  position: relative;
}

/* The dropdown menu itself */
.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  min-width: 180px;

  /* --- GLASS EFFECT ADDED --- */
  background-color: var(--glass-bg); /*Use the semi-transparent background */
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px); /* For Safari browser support */

  border-radius: 0.75rem;
  padding: 0.5rem;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
  border: 1px solid var(--glass-border); /* Use the glass border color */

  /* --- Hiding/Showing properties (unchanged) --- */
  opacity: 50;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
  z-index: 100;
}

/* Show the menu when hovering over the container */
.dropdown-container:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

/* Styling for the links inside the dropdown */
.dropdown-menu a {
  display: block;
  padding: 0.75rem 1rem; /* 12px 16px */
  color: var(--text-gray-dark);
  border-radius: 0.5rem; /* 8px */
  transition: background-color 0.2s ease, color 0.2s ease;
  white-space: nowrap; /* Prevent text from wrapping */
}

.dropdown-menu a:hover {
  background-color: rgba(0, 0, 0, 0.09);
  color: var(--text-color);
}

/* --- Back to Home Link Styles --- */
.back-link {
  font-weight: 600;
  color: var(--text-gray-dark);
  padding: 0.5rem 1rem 0.5rem 0.75rem;
  border-radius: 9999px;
  background-color: var(--glass-bg);
  border: 1px solid var(--glass-border);
  transition: all 0.3s ease;
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
}

.back-link:hover {
  color: var(--text-color);
  background-color: var(--form-input-bg);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.07);
}

/* --- Flipping Commitment Card Styles --- */

.commitment-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 1rem;
}

@media (min-width: 768px) {
  .commitment-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* The container for each card, which creates the 3D space */
.commitment-flip-card {
  width: 290px;
  margin: 0 auto;
  background-color: transparent;
  height: 190px; /* REDUCED: Was 280px */
  perspective: 1000px;
  cursor: pointer;
}

/* This is the element that actually flips */
.commitment-flip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.8s;
  transform-style: preserve-3d;
}

/* The hover effect that triggers the flip */
.commitment-flip-card:hover .commitment-flip-card-inner {
  transform: rotateY(180deg);
}

/* Common styles for both the front and back faces of the card */
.commitment-flip-card-front,
.commitment-flip-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem; /* REDUCED: Was 2rem */
  border-radius: 1.5rem;
  border: 2px solid var(--accent-color-light);
  background-color: var(--glass-bg);
}

/* The back face starts off hidden, rotated 180 degrees */
.commitment-flip-card-back {
  transform: rotateY(180deg);
  padding: 2rem; /* REDUCED: Was 2.5rem */
}

/* Re-styling for the icon and title to fit the new structure */
.commitment-card-icon {
  margin: 0 auto 1rem; /* REDUCED: Bottom margin */
  height: 3.5rem; /* REDUCED: Was 4rem */
  width: 3.5rem; /* REDUCED: Was 4rem */
  color: var(--text-color);
  background-color: var(--panel-bg);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  border: 1px solid var(--glass-border);
}

.commitment-flip-card-front h3 {
  font-size: 1.25rem; /* REDUCED: Was 1.5rem */
  font-weight: 700;
  text-align: center;
}

/* NEW: Slightly smaller text on the back to fit better */
.commitment-flip-card-back p {
  font-size: 1rem;
  color: var(--text-color);
  text-align: justify;
}

/* --- Add this to the bottom of style.css --- */

/* 1. Prepare the card faces to contain the shine effect */
.commitment-flip-card-front,
.commitment-flip-card-back {
  /* This is crucial to ensure the shine doesn't appear outside the card */
  overflow: hidden;
}

/* 2. Define the shine element itself */
.commitment-flip-card-front::after,
.commitment-flip-card-back::after {
  content: '';
  position: absolute;
  top: -100%;
  left: -100%;
  width: 50%;
  height: 300%;
  pointer-events: none;

  /* This gradient creates the soft, silver line of light */
  background: linear-gradient(
    to right,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.25) 100%,
    /* A semi-transparent white works best for a "shine" */
      rgba(133, 133, 133, 0) 100%
  );

  /* This sets the angle and starting position (off-screen top-right) */
  transform: rotate(-45deg) translateX(-250%);
  transition: transform 0s; /* No transition by default */
}

/* 3. Define the keyframes that move the shine */
@keyframes move-shine-effect {
  0% {
    /* Starts off-screen (top-right) */
    transform: rotate(-45deg) translateX(-250%);
  }
  100% {
    /* Ends off-screen (bottom-left) */
    transform: rotate(-45deg) translateX(250%);
  }
}

/* 4. Trigger the animation when you hover over the card */
.commitment-flip-card:hover .commitment-flip-card-front::after,
.commitment-flip-card:hover .commitment-flip-card-back::after {
  animation: move-shine-effect 1.2s ease-in-out;
  animation-delay: 0.1s; /* Optional: adds a slight delay before the shine starts */
}

/* --- Trending Post Cards (blur first → clear on hover) --- */

/* Container for each card */
.tech-scroller .trending-post-card {
  position: relative; /* overlay positioned relative to this */
  display: block;
  width: 250px; /* tweak as needed */
  height: 300px; /* tweak as needed */
  flex-shrink: 0; /* keeps card size inside horizontal scroller */
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.08);
  transition: transform 0.28s ease;
  background-color: #e2e8f0; /* fallback while image loads */
  -webkit-tap-highlight-color: transparent;
}

.tech-scroller .trending-post-card:hover,
.tech-scroller .trending-post-card.is-touched {
  transform: translateY(-6px);
}

/* Image (blurred by default) */
.tech-scroller .trending-post-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: blur(2px) brightness(0.8); /* blurred initially */
  transition: transform 0.5s cubic-bezier(0.2, 0.9, 0.2, 1), filter 0.45s ease;
  z-index: 1;
  will-change: transform, filter;
}

/* On hover → clear image */
.tech-scroller .trending-post-card:hover .trending-post-image,
.tech-scroller .trending-post-card.is-touched .trending-post-image {
  filter: blur(0) brightness(1);
  transform: scale(1.02);
}

/* Overlay (always visible) */
.tech-scroller .trending-post-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.3rem;
  gap: 0.6rem;
  color: #5c5d5f; /* UPDATED: Changed text color to dark */
  background: linear-gradient(
    to top,
    rgba(255, 255, 255, 0.9) 0%,
    /* UPDATED: White gradient */ rgba(255, 255, 255, 0.5) 40%,
    /* UPDATED: Fading to transparent */ transparent 70%
  );
  transition: text-shadow 0.35s ease, opacity 0.35s ease;
  pointer-events: auto;
}

/* Overlay text styles */
.tech-scroller .trending-post-category {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.95;
}

.tech-scroller .trending-post-title {
  margin: 0.25rem 0 0.8rem;
  font-size: 1.15rem;
  font-weight: 800;
  line-height: 1.18;
  text-shadow: none;
}

.tech-scroller .trending-post-link {
  font-weight: 700;
  font-size: 0.92rem;
  color: #5c5d5f;
  text-decoration: none;
  align-self: flex-start;
  transition: transform 0.22s ease, opacity 0.22s ease;
}

/* Highlight overlay text more on hover */
.tech-scroller .trending-post-card:hover .trending-post-overlay,
.tech-scroller .trending-post-card.is-touched .trending-post-overlay {
  text-shadow: 0 6px 18px rgba(0, 0, 0, 0.7);
}

/* Accessibility focus */
.tech-scroller .trending-post-card:focus {
  outline: 3px solid rgba(59, 130, 246, 0.25);
  outline-offset: 4px;
}

/* Responsive adjustments */
@media (max-width: 900px) {
  .tech-scroller .trending-post-card {
    width: 260px;
    height: 340px;
  }
}

@media (max-width: 480px) {
  .tech-scroller .trending-post-card {
    width: calc(100% - 48px);
    height: 240px;
  }
}

/* --- Animated Developer Signature --- */
.developer-credit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem; /* 12px */
  margin-top: 1.5rem; /* 24px */
  font-size: 1rem; /* 16px */
  font-weight: 500;
  color: var(--text-gray-light);
  position: relative;
  padding-bottom: 8px; /* Space for the animated line */
}

/* The animated line underneath */
.developer-credit::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0%;
  height: 2px;
  background: linear-gradient(90deg, transparent, #9ca3af, transparent);
  animation: expand-line 3s infinite alternate;
}

/* Keyframes for the line animation */
@keyframes expand-line {
  from {
    width: 0%;
    opacity: 0.5;
  }
  to {
    width: 40%;
    opacity: 1;
  }
}

/* Styling for the MHG link */
.mhg-link {
  font-weight: 700;
  color: var(--text-gray-dark);
  text-decoration: none;
  display: inline-block;
  transition: color 0.3s ease;
}

/* Styling for individual characters for hover effect */
.mhg-link .char {
  display: inline-block;
  transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1), color 0.3s ease;
}

/* The hover animation */
.developer-credit:hover .mhg-link {
  color: var(--text-color);
}

.developer-credit:hover .mhg-link .char {
  transform: translateY(-3px) scale(1.05);
}

/* Stagger the animation for each character on hover */
.developer-credit:hover .mhg-link .char:nth-child(1) {
  transition-delay: 0s;
}
.developer-credit:hover .mhg-link .char:nth-child(2) {
  transition-delay: 0.05s;
}
.developer-credit:hover .mhg-link .char:nth-child(3) {
  transition-delay: 0.1s;
}

/* --- NEW: Legal & Policy Page Structure --- */
.policy-container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  align-items: flex-start;
}

@media (min-width: 1024px) {
  .policy-container {
    grid-template-columns: 280px 1fr; /* Sidebar width and main content */
    gap: 4rem;
  }
}

.policy-sidebar {
  position: sticky;
  top: 120px; /* Adjust based on your header height */
  padding: 1.5rem;
  border-radius: 1rem;
  background-color: var(--form-input-bg);
  border: 1px solid var(--form-input-border);
}

.policy-sidebar h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-color);
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--form-input-border);
}

.policy-sidebar ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.policy-sidebar a {
  display: block;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  font-weight: 500;
  color: var(--text-gray-dark);
  text-decoration: none;
  transition: all 0.2s ease-in-out;
  position: relative;
  overflow: hidden;
}

.policy-sidebar a:hover {
  background-color: var(--glass-bg);
  color: var(--text-color);
  transform: translateX(5px);
}

.policy-content .prose {
  max-width: 100%; /* Ensure prose takes full width of its container */
}

/* Customizing prose styles to match your theme */
.prose h2 {
  color: var(--text-color);
  font-weight: 700;
  margin-top: 2.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--form-input-border);
}

.prose a {
  color: var(--text-color);
  font-weight: 600;
  text-decoration: underline;
  transition: color 0.2s ease;
}

.prose a:hover {
  color: var(--text-gray-dark);
}

.prose strong {
  color: var(--text-color);
}

.prose ul > li::before {
  background-color: var(--text-gray-dark);
}
