/* =====================================================
   AGGREKO AR EXPERIENCE – MAIN STYLESHEET (LIGHT THEME)
   ===================================================== */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Aggreko brand tokens — matches aggreko.com + 2026 brand guidelines */
:root {
  --orange:        #FD6E39;
  --orange-light:  #FF8B5E;
  --orange-dark:   #E4571F;
  --orange-glow:   rgba(253, 110, 57, 0.18);
  --orange-soft:   rgba(253, 110, 57, 0.09);
  --orange-border: rgba(253, 110, 57, 0.3);

  --black:         #101010;
  --cream:         #FBFAF5;

  --bg:            var(--cream);
  --bg-white:      #ffffff;
  --card-bg:       #ffffff;
  --card-border:   rgba(16, 16, 16, 0.08);
  --card-shadow:   0 1px 3px rgba(16, 16, 16, 0.05);

  --text-primary:  var(--black);
  --text-body:     #3a3a3a;
  --text-muted:    #6c6c6c;
  --text-subtle:   #b8b4b3;

  --header-bg:     rgba(251, 250, 245, 0.9);
  --header-border: rgba(16, 16, 16, 0.08);

  --radius:        20px;
  --radius-sm:     12px;
  --radius-pill:   27px;
  --transition:    0.3s cubic-bezier(0.16, 1, 0.3, 1);
  --font:          'Inter Tight', 'Inter', system-ui, -apple-system, sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text-primary);
  min-height: 100dvh;
  overflow-x: hidden;
  position: relative;
}

/* ---- Background Orbs ---- */
.bg-orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(90px);
  pointer-events: none;
  z-index: 0;
}

.orb-1 {
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(253,110,57,0.1) 0%, transparent 70%);
  top: -160px;
  right: -100px;
  animation: orbFloat 12s ease-in-out infinite alternate;
}

.orb-2 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(253,110,57,0.06) 0%, transparent 70%);
  bottom: 5%;
  left: -100px;
  animation: orbFloat 16s ease-in-out infinite alternate-reverse;
}

@keyframes orbFloat {
  from { transform: translateY(0) scale(1); }
  to   { transform: translateY(40px) scale(1.06); }
}

/* ---- Header — floating pill bar, per aggreko.com ---- */
.site-header {
  position: sticky;
  top: 12px;
  z-index: 100;
  padding: 14px 20px 0;
}

.header-inner {
  max-width: 1040px;
  margin: 0 auto;
  padding: 9px 9px 9px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--header-bg);
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  border: 1px solid var(--header-border);
  border-radius: 12px;
  box-shadow: 0 2px 18px rgba(16,16,16,0.08);
}

.logo {
  height: 32px;
  object-fit: contain;
}

/* Orange pill, like the aggreko.com header CTA */
.help-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--orange);
  border: 2px solid transparent;
  color: var(--black);
  padding: 9px 20px;
  border-radius: var(--radius-pill);
  font-family: var(--font);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.help-btn svg {
  width: 15px;
  height: 15px;
}

.help-btn:hover {
  background: var(--black);
  color: var(--cream);
}

/* ---- Hero ---- */
.hero {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 60px 24px 36px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: var(--orange-soft);
  border: 1px solid var(--orange-border);
  color: var(--orange-dark);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 5px 15px 5px 10px;
  border-radius: var(--radius-pill);
  margin-bottom: 22px;
}

.badge-dot {
  width: 7px;
  height: 7px;
  background: var(--orange);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.45; transform: scale(0.65); }
}

.hero-title {
  font-size: clamp(2.4rem, 6vw, 4rem);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  margin-bottom: 18px;
}

.hero-title .highlight {
  color: var(--orange);
}

.hero-sub {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 440px;
  margin: 0 auto;
  line-height: 1.65;
}

/* ---- Products Section ---- */
.products-section {
  position: relative;
  z-index: 1;
  padding: 24px 20px 72px;
  max-width: 1040px;
  margin: 0 auto;
}

.products-grid {
  display: grid;
  gap: 22px;
  grid-template-columns: 1fr;
}

@media (min-width: 560px) {
  .products-grid { grid-template-columns: repeat(2, 1fr); }
}

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

/* ---- Product Card ---- */
.product-card {
  display: flex;
  flex-direction: column;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
  cursor: pointer;
  position: relative;
  box-shadow: var(--card-shadow);
}

.product-card:hover {
  transform: translateY(-4px);
  border-color: rgba(16, 16, 16, 0.16);
  box-shadow: 0 10px 30px rgba(16, 16, 16, 0.08);
}

/* Card Image */
.card-image-wrap {
  position: relative;
  aspect-ratio: 16/10;
  overflow: hidden;
  background: #f2ede9;
}

/* Brand frame device — corner brackets fade in and expand toward the
   image corners on hover, easing to a stop while the cursor stays */
.card-image-wrap::before,
.card-image-wrap::after {
  content: '';
  position: absolute;
  width: 22px;
  height: 22px;
  border: 3px solid var(--orange);
  opacity: 0;
  transition: top 0.55s cubic-bezier(0.16, 1, 0.3, 1),
              left 0.55s cubic-bezier(0.16, 1, 0.3, 1),
              right 0.55s cubic-bezier(0.16, 1, 0.3, 1),
              bottom 0.55s cubic-bezier(0.16, 1, 0.3, 1),
              opacity 0.4s ease-out;
  pointer-events: none;
}

.card-image-wrap::before {
  top: 34px;
  left: 34px;
  border-right: none;
  border-bottom: none;
}

.card-image-wrap::after {
  bottom: 34px;
  right: 34px;
  border-left: none;
  border-top: none;
}

.product-card:hover .card-image-wrap::before {
  top: 10px;
  left: 10px;
  opacity: 1;
}

.product-card:hover .card-image-wrap::after {
  bottom: 10px;
  right: 10px;
  opacity: 1;
}

.card-thumb {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 14px;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  display: block;
}

.product-card:hover .card-thumb {
  transform: scale(1.05);
}

.card-image-overlay {
  position: absolute;
  top: 12px;
  right: 12px;
}

.ar-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(251,250,245,0.94);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(16,16,16,0.1);
  color: var(--black);
  font-size: 0.67rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 20px;
}

.ar-badge svg { color: var(--orange); }

/* Card Body — fills the card so the CTA pins to the bottom edge */
.card-body {
  flex: 1;
  padding: 18px 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.card-meta { display: flex; align-items: center; }

.card-category {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--orange-dark);
}

.card-title {
  font-size: 1.2rem;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.card-desc {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.65;
  flex: 1;
}

/* AR Button */
/* Card CTA — outline pill that fills black on hover,
   like aggreko.com "View product information" */
.ar-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: transparent;
  color: var(--black);
  font-family: var(--font);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  border: 2px solid var(--black);
  border-radius: var(--radius-pill);
  padding: 11px 20px;
  cursor: pointer;
  transition: var(--transition);
  margin-top: auto;
}

.ar-button:hover {
  background: var(--black);
  color: #ffffff;
}

/* Arrow motif on CTAs, nudges right on hover */
.btn-arrow {
  flex-shrink: 0;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.ar-button:hover .btn-arrow,
.modal-cta:hover .btn-arrow {
  transform: translateX(4px);
}

/* ---- Footer — black panel with cream text, per aggreko.com ---- */
.site-footer {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 36px 20px;
  color: var(--cream);
  font-size: 0.82rem;
  background: #000000;
}

/* =====================================================
   HELP MODAL
   ===================================================== */

.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 900;
  background: rgba(0,0,0,0.35);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}

@media (min-width: 600px) {
  .modal-overlay { align-items: center; padding: 24px; }
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.modal-box {
  background: var(--cream);
  border: 1px solid rgba(16,16,16,0.08);
  box-shadow: 0 24px 80px rgba(16,16,16,0.18);
  border-radius: var(--radius) var(--radius) 0 0;
  width: 100%;
  max-width: 640px;
  max-height: 90dvh;
  overflow-y: auto;
  padding: 28px 24px 36px;
  position: relative;
  transform: translateY(40px);
  transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
  scrollbar-width: thin;
  scrollbar-color: var(--orange-border) transparent;
}

@media (min-width: 600px) {
  .modal-box {
    border-radius: var(--radius);
    transform: scale(0.95) translateY(16px);
    max-height: 85dvh;
  }
}

.modal-overlay.active .modal-box {
  transform: translateY(0);
}

@media (min-width: 600px) {
  .modal-overlay.active .modal-box {
    transform: scale(1) translateY(0);
  }
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: transparent;
  border: 1px solid rgba(16,16,16,0.12);
  color: var(--text-muted);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.modal-close:hover {
  background: var(--black);
  border-color: var(--black);
  color: var(--cream);
}

.modal-icon {
  width: 52px;
  height: 52px;
  background: var(--orange);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--black);
  margin-bottom: 14px;
}

.modal-title {
  font-size: 1.7rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.modal-intro {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 20px;
}

.modal-sections {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.modal-section {
  display: flex;
  gap: 14px;
  padding: 18px;
  background: #ffffff;
  border: 1px solid rgba(16,16,16,0.07);
  border-radius: var(--radius);
}

.section-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* One accent only: orange on soft orange, per brand */
.section-icon--space,
.section-icon--android,
.section-icon--ios,
.section-icon--tip {
  background: var(--orange-soft);
  color: var(--orange-dark);
}

.modal-section h3 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 7px;
  color: var(--text-primary);
}

.modal-section p {
  font-size: 0.81rem;
  color: var(--text-body);
  line-height: 1.65;
  margin-bottom: 6px;
}

.modal-section p:last-child { margin-bottom: 0; }

.modal-section ul,
.modal-section ol {
  padding-left: 18px;
  font-size: 0.81rem;
  color: var(--text-body);
  line-height: 1.85;
  margin-bottom: 6px;
}

.modal-section ol li::marker {
  color: var(--orange-dark);
  font-weight: 600;
}

/* Brand arrow bullets */
.arrow-list {
  list-style: none;
  padding-left: 0 !important;
}

.arrow-list li {
  position: relative;
  padding-left: 24px;
}

.arrow-list li::before {
  content: '\2192';
  position: absolute;
  left: 0;
  color: var(--orange);
  font-weight: 600;
}

.modal-section strong {
  color: var(--text-primary);
  font-weight: 700;
}

.modal-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  margin-top: 22px;
  background: var(--black);
  color: #ffffff;
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 600;
  border: 2px solid var(--black);
  border-radius: var(--radius-pill);
  padding: 14px 24px;
  cursor: pointer;
  transition: var(--transition);
}

.modal-cta:hover {
  background: var(--orange);
  border-color: var(--orange);
  color: var(--black);
}

/* ---- Safe Area ---- */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
  .modal-box { padding-bottom: calc(36px + env(safe-area-inset-bottom)); }
}
