/* =============================================
   INTEL SUSTAINABILITY TIMELINE - CSS
   Condensed & optimized for learning
   ============================================= */

/* ===== GLOBAL RESET ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, #f0f4f8 0%, #e8f1f7 100%);
  color: #333;
  line-height: 1.6;
}

/* RTL text alignment helpers */
html[dir="rtl"] body {
  text-align: right;
}

html[dir="rtl"] .features-header,
html[dir="rtl"] .newsletter-header,
html[dir="rtl"] .feature-card,
html[dir="rtl"] .flip-card,
html[dir="rtl"] .newsletter-form,
html[dir="rtl"] .site-footer {
  text-align: right;
}

html[dir="rtl"] .features-grid,
html[dir="rtl"] .newsletter-form {
  direction: rtl;
}

html[dir="rtl"] .form-group label {
  text-align: right;
}

html[dir="rtl"] .checkin-card,
html[dir="rtl"] .check-in-form,
html[dir="rtl"] .team-stats {
  text-align: right;
}

/* ===== ACCESSIBILITY: FOCUS STYLES ===== */
button:focus,
button:focus-visible {
  outline: 3px solid #00c7fd;
  outline-offset: 2px;
}

.flip-card:focus,
.flip-card:focus-visible {
  outline: 3px solid #00c7fd;
  outline-offset: 2px;
}

/* ===== LANGUAGE SWITCHER ===== */
.lang-btn {
  position: absolute;
  top: 20px;
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.9);
  border: 2px solid #0071c5;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.9em;
  font-weight: 600;
  color: #0071c5;
  transition: all 0.3s ease;
  z-index: 100;
}

.lang-btn-en {
  left: 20px;
}

html[dir="rtl"] .lang-btn-en {
  left: auto;
  right: 20px;
}

.lang-btn-ar {
  right: 20px;
}

html[dir="rtl"] .lang-btn-ar {
  right: auto;
  left: 20px;
}

.lang-btn:hover {
  background: white;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* ===== HEADER / HERO SECTION ===== */
header {
  background: linear-gradient(135deg, rgba(0, 113, 197, 0.4) 0%, rgba(0, 74, 148, 0.4) 50%, rgba(0, 199, 253, 0.4) 100%),
              linear-gradient(to right, transparent 40%, #f0f4f8 100%),
              linear-gradient(to left, transparent 40%, #f0f4f8 100%), 
              url('img/intel-1.avif') left center/auto 100% no-repeat,
              url('img/intel-7.avif') right center/auto 100% no-repeat;
  background-size: 100% 100%, 100% 100%, 100% 100%, auto 100%, auto 100%;
  background-position: center, left center, right center, left center, right center;
  position: relative;
  color: white;
  padding: 80px 20px;
  text-align: center;
  box-shadow: 0 8px 32px rgba(0, 113, 197, 0.3);
  overflow: hidden;
  min-height: 450px; /* Optimized height for laptop */
  max-height: 500px; /* Prevents header from being too tall */
}

/* Mobile optimization for background */
@media (max-width: 768px) {
  header {
    background-attachment: scroll; /* Fixes mobile background display issues */
    background-size: 100% auto; /* Make photo smaller on mobile */
    background-position: center center; /* Reset to center on mobile */
    min-height: 350px;
    max-height: none;
    padding: 60px 15px;
    margin-bottom: 20px; /* Smaller gap between header and cards */
  }
  
  header div {
    max-width: 100%;
  }
}

/* Animated overlay */
header::before {
  content: '';
  position: absolute;
  inset: 0;  /* Shorthand for top: 0, right: 0, bottom: 0, left: 0 */
  background: radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
              radial-gradient(circle at 80% 80%, rgba(0, 199, 253, 0.15) 0%, transparent 50%);
  pointer-events: none;
  animation: shimmer 15s ease-in-out infinite;
}

@keyframes shimmer {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.8; }
}

header div {
  max-width: 900px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
  animation: slideDown 0.8s ease-out;
}

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-30px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Logo */
header img {
  max-width: 140px;
  height: auto;
  margin-bottom: 40px;
  margin-top: -20px;
  margin-inline-start: 25px; /* Works for both LTR and RTL */
  filter: brightness(0) invert(1) drop-shadow(0 2px 8px rgba(0, 0, 0, 0.2));
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), filter 0.4s ease;
}

header img:hover {
  transform: scale(1.08) rotate(-2deg);
  filter: brightness(0) invert(1) drop-shadow(0 4px 12px rgba(0, 0, 0, 0.3));
}

/* Headline */
header h1 {
  font-size: 3em;
  margin-bottom: 20px;
  font-weight: 700;
  letter-spacing: -0.5px;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.3);
  line-height: 1.2;
  animation: fadeInScale 0.9s ease-out 0.1s both;
}

@keyframes fadeInScale {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

/* Subheading */
header p {
  font-size: 1.2em;
  opacity: 0.98;
  line-height: 1.8;
  margin: 60px 0 0;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.2);
  animation: fadeInUp 0.9s ease-out 0.2s both;
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ===== TIMELINE SECTION ===== */
section {
  max-width: 100%;
  margin: 16px auto 40px;
  padding: 8px 16px;
  position: relative;
}

.timeline-hint {
  margin: 0;
  padding: 0;
}

/* ===== CHECK-IN SECTION ===== */
.checkin-section {
  padding: 14px 10px 2px;
}

.checkin-section .container {
  max-width: 1200px;
}

.checkin-grid {
  gap: 12px;
}

.checkin-col {
  flex: 1 1 0;
}

.checkin-col-primary {
  flex: 5 1 0;
}

.checkin-col-secondary {
  flex: 1 1 0;
}

.checkin-card {
  background: #ffffff;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 4px 12px rgba(0, 113, 197, 0.1);
  border-inline-start: 6px solid #0071c5;
}

.checkin-primary {
  padding: 18px;
  min-height: 720px;
}

.simple-list {
  list-style: none;
  padding: 0;
  margin: 0;
  max-height: 260px;
  overflow-y: auto;
  border: 1px solid #e6eef7;
  border-radius: 8px;
}

.simple-list li {
  padding: 8px 10px;
  border-bottom: 1px solid #e6eef7;
  font-size: 0.95em;
}

.simple-list li:last-child {
  border-bottom: none;
}

.chat-form label {
  display: block;
  margin-top: 8px;
  font-weight: 600;
}

.chat-form input {
  width: 100%;
  margin-top: 6px;
  padding: 10px;
  border: 1px solid #cfd8dc;
  border-radius: 6px;
  font-size: 1em;
}

.chat-form button {
  margin-top: 12px;
  padding: 10px 16px;
  border: none;
  border-radius: 6px;
  background: #0071c5;
  color: #ffffff;
  font-weight: 600;
  cursor: pointer;
}

.chat-form button:hover {
  background: #005a9e;
}
}

/* Keep the check-in card still (no hover bounce) */
.checkin-section > div,
.checkin-section > div:hover {
  transform: none;
  box-shadow: 0 4px 12px rgba(0, 113, 197, 0.1);
  border-top-color: transparent;
  border-inline-start-color: #0071c5;
}

.checkin-subtitle {
  color: #555;
  margin: 8px 0 20px;
}

.attendance-tracker {
  margin: 8px 0;
  text-align: center;
}

.attendance-count {
  font-weight: 600;
  color: #0071c5;
  text-align: center;
}

.goal-message {
  margin: 10px 0 16px;
  padding: 10px 14px;
  border-radius: 10px;
  background: linear-gradient(90deg, #e8f9f0, #f1fbff);
  border: 1px solid #cfeee0;
  font-weight: 800;
  color: #0f5132;
  letter-spacing: 0.3px;
  text-align: center;
  box-shadow: 0 4px 10px rgba(0, 113, 197, 0.08);
}

.team-win-message {
  margin: 8px 0 12px;
  padding: 8px 12px;
  border-radius: 10px;
  background: #f7fbff;
  border: 1px solid #d6e6f7;
  font-weight: 700;
  color: #0071c5;
  text-align: center;
}

.team-win-message:empty,
.goal-message:empty {
  display: none;
}

.goal-subtext {
  display: block;
  margin-top: 6px;
  font-weight: 400;
}

.goal-underline {
  text-decoration: underline;
}

.goal-team {
  display: block;
  margin-top: 4px;
  margin-inline-start: 12px;
  font-weight: 400;
}

.progress-container {
  background: #e6eef7;
  border-radius: 12px;
  overflow: hidden;
  height: 22px;
}

.progress-bar {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #0071c5, #00c7fd);
  color: #ffffff;
  font-size: 0.8em;
  text-align: center;
  line-height: 22px;
}

.greeting-message {
  min-height: 24px;
  margin: 12px 0 16px;
  color: #1b5e20;
  font-weight: 600;
}

.check-in-form label {
  display: block;
  margin-top: 12px;
  font-weight: 600;
}

.check-in-form .form-group {
  margin-top: 10px;
}

.check-in-form .input-wrapper {
  margin-top: 6px;
}

.check-in-form input,
.check-in-form select {
  width: 100%;
  margin-top: 6px;
  padding: 10px;
  border: 1px solid #cfd8dc;
  border-radius: 6px;
  font-size: 1em;
}

.check-in-form button {
  margin-top: 16px;
  padding: 10px 16px;
  border: none;
  border-radius: 6px;
  background: #0071c5;
  color: #ffffff;
  font-weight: 600;
  cursor: pointer;
}

.check-in-form button:hover {
  background: #005a9e;
}

.reset-section {
  padding: 0;
  margin: 0;
  text-align: center;
}


.reset-btn {
  padding: 3px 6px;
  border: none;
  outline: none;
  box-shadow: none;
  border-radius: 6px;
  background: #e53935;
  color: #ffffff;
  font-weight: 600;
  font-size: 0.7em;
  cursor: pointer;
}

.reset-btn:hover {
  background: #c62828;
}

.team-stats {
  margin-top: 12px;
  text-align: center;
}

.team-panel {
  padding: 16px;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 113, 197, 0.1);
  border-top: 3px solid #0071c5;
  margin-left: auto;
  margin-right: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 900px;
  margin-top: 48px;
  margin-bottom: 48px;
}

.team-cards {
  display: flex;
  margin-top: 8px;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}
}

.team-card {
  flex: 0 0 auto;
  background: #f7fbff;
  border: 1px solid #d6e6f7;
  border-radius: 8px;
  padding: 20px 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 500px;
  height: auto;
  gap: 20px;
}

.team-card.water {
  background: #e9f6ff;
}

.team-card.zero {
  background: #ecf9f0;
}

.team-card.power {
  background: #fff6e8;
}

.team-name {
  font-weight: 600;
}

.team-count {
  color: #0071c5;
  font-weight: 700;
  display: inline-block;
  min-width: 30px;
  text-align: right;
}
}

/* Timeline cards */
section > div {
  flex: 0 0 auto;
  width: 100%;
  background: white;
  border-radius: 12px;
  padding: 30px;
  margin-bottom: 30px;
  box-shadow: 0 4px 12px rgba(0, 113, 197, 0.1);
  border-inline-start: 6px solid #0071c5; /* Works for both LTR and RTL */
  border-top: 3px solid transparent;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  transform: translateY(0) scale(1);
  position: relative;
  overflow: hidden;
  perspective: 1000px;
}

section > div:hover {
  transform: none;
  box-shadow: 
    0 6px 16px rgba(0, 113, 197, 0.15),
    0 12px 24px rgba(0, 113, 197, 0.2),
    0 20px 40px rgba(0, 199, 253, 0.12);
  border-inline-start-color: #00c7fd; /* Works for both LTR and RTL */
  border-top-color: #00c7fd;
}

section.features-section > div,
section.features-section > div:hover,
section.attendee-section > div,
section.attendee-section > div:hover {
  transform: none;
  box-shadow: none;
  border-inline-start-color: transparent;
  border-top-color: transparent;
  transition: none;
}

section.newsletter-section > div,
section.newsletter-section > div:hover {
  transform: none;
  box-shadow: none;
  border-inline-start-color: transparent;
  border-top-color: transparent;
  transition: none;
}

section.features-section > div:hover h2,
section.features-section > div:hover h3,
section.attendee-section > div:hover h2,
section.attendee-section > div:hover h3 {
  transform: none;
  color: inherit;
}

section.newsletter-section > div:hover h2 {
  transform: none;
  color: inherit;
}

/* Card text - Year */
section > div h2 {
  font-size: 2.5em;
  color: #0071c5;
  margin-bottom: 10px;
  font-weight: 700;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  line-height: 1.1;
  transform: translateX(0);
}

section > div:hover h2 {
  color: #00c7fd;
  transform: translateX(8px);
}

/* Card text - Title */
section > div h3 {
  font-size: 1.5em;
  color: #222;
  margin-bottom: 15px;
  font-weight: 600;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  line-height: 1.3;
  transform: translateX(0);
}

section > div:hover h3 {
  color: #0071c5;
  transform: translateX(6px);
}

/* Card text - Description */
section:not(.features-section):not(.newsletter-section) > div:not(.flip-card) p {
  font-size: 1em;
  color: #666;
  line-height: 1.8;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  margin: 0;
  opacity: 0;
  max-height: 0;
  overflow: hidden;
}

/* Show details when card has 'active' class (clicked) */
section:not(.features-section):not(.newsletter-section) > div:not(.flip-card).active p {
  color: #333;
  opacity: 1;
  max-height: 500px;
  margin-top: 10px;
}

/* ===== FLIP CARD STYLES ===== */
/* Flip card container */
.flip-card {
  background: white;
  border-radius: 12px;
  padding: 30px;
  margin: 8px auto 12px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 113, 197, 0.1);
  border-inline-start: 6px solid #0071c5; /* Works for both LTR and RTL */
  border-top: 3px solid transparent;
  perspective: 1000px;
  min-width: 280px; /* Smaller cards on phone */
  max-width: 100%;
}

/* Static title and year */
.flip-card h2 {
  font-size: 2.5em;
  color: #0071c5;
  margin-bottom: 10px;
  font-weight: 700;
  line-height: 1.1;
}

.flip-card h3 {
  font-size: 1.5em;
  color: #222;
  margin-bottom: 25px; /* More space before the photo */
  font-weight: 600;
  line-height: 1.3;
}

/* Inner container for flipping */
.flip-card-inner {
  position: relative;
  width: 100%;
  height: 280px; /* Taller cards to fit text and photo */
  text-align: center;
  transition: transform 0.6s;
  transform-style: preserve-3d;
}

/* Flip the inner card when clicked */
.flip-card.flipped .flip-card-inner {
  transform: rotateY(180deg);
}

/* Front and back faces */
.flip-card-front,
.flip-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 8px;
  overflow: visible;
}

/* Front face - show image */
.flip-card-front {
  background: #f0f4f8;
}

.flip-card-front img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  margin: 0;
}

/* Different focus positions for each flip card */
.flip-card:nth-of-type(1) .flip-card-front img {
  object-position: right center;
}

.flip-card:nth-of-type(2) .flip-card-front img {
  object-position: center center;
}

.flip-card:nth-of-type(3) .flip-card-front img {
  object-position: center center;
}

.flip-card:nth-of-type(4) .flip-card-front img {
  object-position: center center;
}

.flip-card:nth-of-type(5) .flip-card-front img {
  object-position: center center;
}

.flip-card:nth-of-type(6) .flip-card-front img {
  object-position: center center;
}

.flip-card:nth-of-type(7) .flip-card-front img {
  object-position: center center;
}

.flip-card:nth-of-type(8) .flip-card-front img {
  object-position: center center;
}

/* Back face - show text */
.flip-card-back {
  transform: rotateY(180deg);
  background: #f0f4f8;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  overflow-wrap: break-word;
  word-wrap: break-word;
  word-break: break-word;
}

.flip-card-back p {
  font-size: 1em;
  color: #333;
  line-height: 1.8;
  margin: 0;
  opacity: 1;
  max-height: none;
}

/* Keep flip-card back text visible (override generic section rules) */
section[aria-label="Intel Sustainability Timeline"] .flip-card-back p {
  opacity: 1;
  max-height: none;
  margin: 0;
}

/* Hover effect for flip card */
.flip-card:hover {
  transform: translateY(-12px) scale(1.02);
  box-shadow: 
    0 6px 16px rgba(0, 113, 197, 0.15),
    0 12px 24px rgba(0, 113, 197, 0.2),
    0 20px 40px rgba(0, 199, 253, 0.12);
  border-inline-start-color: #00c7fd; /* Works for both LTR and RTL */
  border-top-color: #00c7fd;
}

.flip-card:hover h2 {
  color: #00c7fd;
}

.flip-card:hover h3 {
  color: #0071c5;
}

/* ===== FEATURES SECTION ===== */
.features-section {
  background: linear-gradient(135deg, #f0f4f8 0%, #e8f1f7 100%);
  padding: 8px 6px;
  margin: 6px 0;
}

.features-section,
.attendee-section {
  position: static;
  transform: none;
  transition: none;
  animation: none;
}

section[aria-labelledby="featureHeadingDuplicate"] {
  margin-bottom: 48px;
}

.features-section > div,
.features-section > div:hover,
.attendee-section > div,
.attendee-section > div:hover {
  transform: none;
  transition: none;
}

.attendee-section {
  padding: 8px 6px;
  margin: 6px 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.attendee-section .container {
  padding: 0 10px;
}

.attendee-section .features-header {
  margin-bottom: 20px;
}

.features-container {
  max-width: 1200px;
  margin: 0 auto;
}

.features-header {
  text-align: center;
  margin-bottom: 12px;
}

.features-section h2,
.features-title {
  font-size: 2em;
  color: #0071c5;
  margin-bottom: 12px;
  font-weight: 700;
  letter-spacing: -0.5px;
  display: inline-block;
  padding: 6px 12px;
  border-radius: 10px;
  background: repeating-linear-gradient(
    135deg,
    #eef6ff,
    #eef6ff 10px,
    #ffffff 10px,
    #ffffff 20px
  );
}

#timelineHeading:hover {
  color: #222;
}

.timeline-block:hover #timelineHeading {
  color: #222;
}

.timeline-block {
  margin-top: 48px;
}

.features-subtitle {
  font-size: 1em;
  color: #666;
  line-height: 1.6;
  margin: 0;
  text-align: center;
}

.features-grid {
  margin-top: 0;
}

.signup-box {
  background: #f4f9ff;
  border: 2px solid #d3e6fb;
  border-radius: 14px;
  padding: 18px;
  box-shadow: 0 6px 16px rgba(0, 113, 197, 0.08);
}

/* Keep attendee pillars equal height */
.attendee-section .features-grid > div {
  display: flex;
}

.attendee-section .feature-card {
  height: 100%;
  min-height: 440px;
  width: 414px;
}


.feature-card {
  background: white;
  padding: 14px 12px;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0, 113, 197, 0.1);
  transition: none;
  border-top: 3px solid #0071c5;
  padding: 6px 10px;
  border-radius: 8px;
  background: repeating-linear-gradient(
    135deg,
    #f2f8ff,
    #f2f8ff 8px,
    #ffffff 8px,
    #ffffff 16px
  );
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.signup-card {
  background: linear-gradient(135deg, #ffffff 0%, #eef7ff 100%);
  border: 2px solid #cfe3f8;
}

.feature-card:hover {
  transform: none;
  box-shadow: 0 4px 12px rgba(0, 113, 197, 0.1);
  border-top-color: #0071c5;
}

.feature-icon {
  font-size: 1.3em;
  display: inline-block;
}

.feature-card h3 {
  font-size: 1.15em;
  color: #0071c5;
  margin-bottom: 10px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.feature-card p {
  font-size: 0.95em;
  color: #666;
  line-height: 1.7;
  margin: 0;
}

/* Simple accordion styling inside pillar cards */
.pillar-accordion {
  margin-top: 10px;
}

.pillar-accordion .accordion-button {
  font-weight: 600;
  color: #0071c5;
}

.pillar-accordion .accordion-button:focus {
  box-shadow: 0 0 0 3px rgba(0, 199, 253, 0.3);
}

.pillar-accordion .accordion-body {
  color: #666;
  line-height: 1.7;
}

.learn-more-btn {
  background: linear-gradient(135deg, #0071c5 0%, #00a8d8 100%);
  color: white;
  border: none;
  padding: 12px 28px;
  border-radius: 8px;
  font-size: 0.95em;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 8px;
  box-shadow: 0 4px 12px rgba(0, 113, 197, 0.2);
}

.learn-more-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0, 113, 197, 0.3);
}

.learn-more-btn:active {
  transform: translateY(-1px);
}

.learn-more-btn:focus {
  outline: 3px solid #00c7fd;
  outline-offset: 2px;
}

/* Make accordion buttons match Learn More style */
.pillar-accordion .accordion-button.learn-more-btn {
  background: linear-gradient(135deg, #0071c5 0%, #00a8d8 100%);
  color: white;
  border: none;
  text-align: center;
  justify-content: center;
}

.pillar-accordion .accordion-button.learn-more-btn:not(.collapsed) {
  color: white;
  background: linear-gradient(135deg, #0071c5 0%, #00a8d8 100%);
}

.pillar-accordion .accordion-button.learn-more-btn::after {
  filter: brightness(0) invert(1);
}

/* ===== NEWSLETTER SECTION ===== */
.newsletter-section {
  background: linear-gradient(135deg, #f0f4f8 0%, #e8f1f7 100%);
  color: #333;
  padding: 60px 16px;
  margin-top: 50px;
}

.newsletter-container {
  max-width: 600px;
  margin: 0 auto;
}

.newsletter-header {
  text-align: center;
  margin-bottom: 32px;
}

.newsletter-section h2 {
  font-size: 2.5em;
  margin-bottom: 20px;
  font-weight: 700;
  letter-spacing: -0.5px;
  display: inline-block;
  padding: 6px 12px;
  border-radius: 10px;
  background: repeating-linear-gradient(
    135deg,
    #eef6ff,
    #eef6ff 10px,
    #ffffff 10px,
    #ffffff 20px
  );
}

.newsletter-subtitle {
  font-size: 1.15em;
  color: #666;
  line-height: 1.8;
  margin: 0;
}

.newsletter-form {
  background: white;
  padding: 36px;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

.form-group {
  margin-bottom: 25px;
}

.form-group label {
  display: block;
  margin-bottom: 12px;
  font-weight: 600;
  color: #333;
  font-size: 1em;
  letter-spacing: 0.3px;
}

.email-input {
  width: 100%;
  padding: 15px 18px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 1em;
  font-family: inherit;
  transition: none;
  background: #f9f9f9;
}

.email-input::placeholder {
  color: #999;
}

.email-input:hover {
  border-color: #0071c5;
  background: white;
}

.email-input:focus {
  border-color: #0071c5;
  outline: none;
  background: white;
  box-shadow: none;
}

.subscribe-btn {
  width: 100%;
  padding: 16px 25px;
  background: linear-gradient(135deg, #0071c5 0%, #00a8d8 100%);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 1.1em;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 15px rgba(0, 113, 197, 0.3);
}

.subscribe-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 15px rgba(0, 113, 197, 0.3);
}

.subscribe-btn:active {
  transform: translateY(-1px);
}

.subscribe-btn:focus {
  outline: 3px solid #00c7fd;
  outline-offset: 2px;
}

.success-message {
  background: #28a745;
  color: white;
  padding: 18px 20px;
  border-radius: 8px;
  margin-top: 25px;
  display: flex;
  align-items: center;
  gap: 12px;
  animation: slideIn 0.4s ease-out;
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}

.success-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  font-size: 1.2em;
  flex-shrink: 0;
}

@keyframes slideIn {
  from { 
    opacity: 0; 
    transform: translateY(-15px);
  }
  to { 
    opacity: 1; 
    transform: translateY(0);
  }
}

/* Instruction text */
body > p {
  text-align: center;
  color: #555;
  font-size: 0.95em;
  margin: 10px 0 25px;
  opacity: 0.8;
  animation: fadeIn 0.6s ease-in;
  padding: 0 20px;
}

/* Simple footer */
.site-footer {
  text-align: center;
  padding: 20px;
  background: #f0f4f8;
  color: #666;
  font-size: 0.9em;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ===== DESKTOP (768px+) ===== */
@media (min-width: 768px) {
  /* Header sizing */
  header h1 { font-size: 3.5em; }
  header p { font-size: 1.3em; }
  
  /* Desktop features section */
  .features-section { padding: 8px 6px; margin: 6px 0; }
  .features-header { margin-bottom: 22px; }
  .features-section h2 { font-size: 2em; margin-bottom: 10px; }
  .features-subtitle { font-size: 0.95em; }
  .feature-card { padding: 24px 20px; }
  .feature-icon { font-size: 2.2em; margin-bottom: 10px; }
  .feature-card h3 { font-size: 1.15em; margin-bottom: 10px; }
  .feature-card p { font-size: 0.95em; line-height: 1.7; }
  .learn-more-btn { padding: 12px 28px; font-size: 0.95em; }


  
  /* Desktop newsletter - wider and shorter */
  .newsletter-section { padding: 32px 16px; margin-top: 40px; }
  .newsletter-container { max-width: 1000px; }
  .newsletter-header { margin-bottom: 18px; }
  .newsletter-section h2 { font-size: 2em; margin-bottom: 12px; }
  .newsletter-subtitle { font-size: 1em; }
  .newsletter-form { padding: 16px; display: flex; gap: 12px; align-items: flex-end; }
  .form-group { flex: 1; min-width: 250px; margin-bottom: 0; }
  .form-group label { margin-bottom: 8px; font-size: 0.9em; }
  .email-input { padding: 12px 15px; }
  .subscribe-btn { width: auto; padding: 12px 35px; font-size: 1em; white-space: nowrap; }
  .success-message { margin-top: 15px; padding: 14px 16px; font-size: 0.95em; }
  
  /* Horizontal scrolling timeline */
  section:not(.newsletter-section):not(.features-section):not(.reset-section) {
    overflow-x: auto;
    overflow-y: hidden;
    padding: 30px 16px;
    scroll-behavior: smooth;
    display: flex;
    gap: 16px;
    align-items: stretch;
    scroll-snap-type: x proximity;
    scroll-padding: 16px;
    scrollbar-width: thin;
    scrollbar-color: #0071c5 #f0f4f8;
  }
  
  /* Timeline line */
  section:not(.newsletter-section):not(.features-section):not(.reset-section)::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 50%;
    height: 4px;
    background: linear-gradient(90deg, #0071c5 0%, #00c7fd 50%, #0071c5 100%);
    z-index: 1;
  }
  
  /* Fixed card width */
  section:not(.newsletter-section):not(.features-section):not(.reset-section) > div {
    width: 300px;
    min-height: 400px;
    margin-bottom: 0;
    z-index: 2;
    scroll-snap-align: center;
    scroll-snap-stop: always;
  }
  
  /* Custom scrollbar */
  section:not(.newsletter-section):not(.features-section):not(.reset-section)::-webkit-scrollbar { height: 10px; }
  section:not(.newsletter-section):not(.features-section):not(.reset-section)::-webkit-scrollbar-track { background: #e8f1f7; border-radius: 10px; }
  section:not(.newsletter-section):not(.features-section):not(.reset-section)::-webkit-scrollbar-thumb { 
    background: linear-gradient(180deg, #0071c5, #00c7fd);
    border-radius: 10px;
    transition: background 0.3s ease;
  }
  section:not(.newsletter-section):not(.features-section):not(.reset-section)::-webkit-scrollbar-thumb:hover { 
    background: linear-gradient(180deg, #004a94, #00a8d8);
  }
}

/* ===== TABLET (481px - 767px) ===== */
@media (min-width: 481px) and (max-width: 767px) {
  header { padding: 50px 16px; }
  header h1 { font-size: 2.5em; margin-bottom: 20px; }
  header p { font-size: 1.1em; line-height: 1.7; }
  header img { max-width: 110px; margin-bottom: 30px; }
  section > div { padding: 25px; }
  section > div h2 { font-size: 2em; }
  section > div h3 { font-size: 1.3em; }

  .features-section { padding: 8px 6px; margin: 6px 0; }
  .features-section h2 { font-size: 1.8em; margin-bottom: 12px; }
  .features-subtitle { font-size: 0.95em; }
  .feature-card { padding: 22px 18px; }
  .feature-icon { font-size: 2.2em; margin-bottom: 10px; }
  .feature-card h3 { font-size: 1.15em; margin-bottom: 10px; }
  .feature-card p { font-size: 0.9em; line-height: 1.6; }
  .learn-more-btn { padding: 10px 24px; font-size: 0.9em; }

  .newsletter-section { padding: 45px 16px; }
  .newsletter-section h2 { font-size: 2em; }
  .newsletter-form { padding: 30px; }
}

/* ===== MOBILE (480px and below) ===== */
@media (max-width: 480px) {
  header { padding: 44px 12px; }
  header h1 { font-size: 2em; margin-bottom: 18px; letter-spacing: -0.3px; }
  header p { font-size: 1em; line-height: 1.6; }
  header img { max-width: 90px; margin-bottom: 25px; }
  section { margin: 24px auto; padding: 0 12px; }
  section > div { padding: 16px; margin-bottom: 16px; border-inline-start-width: 5px; }
  section > div h2 { font-size: 1.8em; }
  section > div h3 { font-size: 1.2em; }
  section:not(.features-section) > div p { font-size: 0.95em; }
  body > p { font-size: 0.9em; margin: 20px 0; padding: 0 12px; }
  
  /* Features section on mobile */
  .features-section { padding: 8px 6px; margin: 6px 0; }
  .features-header { margin-bottom: 18px; }
  .features-section h2 { font-size: 1.6em; margin-bottom: 10px; }
  .features-subtitle { font-size: 0.9em; }
  .feature-card { padding: 18px 14px; }
  .feature-icon { font-size: 2.2em; margin-bottom: 8px; }
  .feature-card h3 { font-size: 1.05em; margin-bottom: 8px; }
  .feature-card p { font-size: 0.85em; line-height: 1.5; }

  /* Smaller flip cards on phone */
  .flip-card { padding: 16px; min-width: 100%; }
  .flip-card h2 { font-size: 1.8em; }
  .flip-card h3 { font-size: 1.2em; }
  .flip-card-inner { height: 220px; }

  /* Newsletter form on mobile */
  .newsletter-section { padding: 30px 12px; margin-top: 40px; }
  .newsletter-section h2 { font-size: 1.8em; margin-bottom: 15px; }
  .newsletter-subtitle { font-size: 1em; }
  .newsletter-form { padding: 22px 16px; }
  .subscribe-btn { padding: 14px 20px; font-size: 1em; }
  .success-message { flex-direction: column; text-align: center; }
}
