/* ============================================================
   TIPTOP INTERNATIONAL — v3
   Tone: bold editorial, white-dominant, navy as accent not wallpaper
   Fonts: Ubuntu (brand primary) + DM Sans (body)
   ============================================================ */

:root {
  --blue:       #021B6D;
  --blue-dark:  #030B34;
  --blue-mid:   #0a2580;
  --blue-lite:  #1a3bb5;
  --silver:     #AFB1B5;
  --silver-dim: #4c5164;
  --white:      #ffffff;
  --off-white:  #F7F8FD;
  --warm-white: #FAFAFA;
  --border:     rgba(2,27,109,0.09);
  --border-lt:  rgba(255,255,255,0.1);

  --font-head: 'Ubuntu', sans-serif;
  --font-body: 'DM Sans', sans-serif;

  --ease:        cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-out:    cubic-bezier(0.16, 1, 0.3, 1);
  --trans: all 0.35s var(--ease);
  --r: 6px;
  --r-lg: 14px;
  --shadow:    0 2px 20px rgba(2,27,109,0.07);
  --shadow-md: 0 8px 36px rgba(2,27,109,0.11);
  --shadow-lg: 0 20px 60px rgba(2,27,109,0.15);
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font-body); background: var(--white); color: var(--silver-dim); overflow-x: hidden; line-height: 1.6; }
body.menu-open { overflow: hidden; touch-action: none; }
img { display: block; max-width: 100%; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
input, select, textarea { font-family: inherit; }

/* ---- Type ---- */
h1, h2, h3, h4, h5 { font-family: var(--font-head); line-height: 1.1; color: var(--blue-dark); font-weight: 700; }
h1 { font-size: clamp(2.8rem, 7vw, 5.5rem); letter-spacing: -0.025em; }
h2 { font-size: clamp(1.9rem, 4.5vw, 3.2rem); letter-spacing: -0.02em; }
h3 { font-size: clamp(1.2rem, 2.5vw, 1.6rem); }
h4 { font-size: 1.05rem; }
p  { font-size: 1rem; line-height: 1.8; color: var(--silver-dim); }

.overline {
  font-family: var(--font-body);
  font-size: 0.68rem; font-weight: 600;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--blue);
  display: flex; align-items: center; gap: 0.75rem;
  margin-bottom: 1rem;
}
.overline::before {
  content: '';
  display: block; width: 28px; height: 2px;
  background: var(--blue); flex-shrink: 0;
}
.overline-light { color: rgba(255,255,255,0.5); }
.overline-light::before { background: rgba(255,255,255,0.4); }

/* ---- Layout ---- */
.container      { max-width: 1200px; margin: 0 auto; padding: 0 2.5rem; }
.container-wide { max-width: 1440px; margin: 0 auto; padding: 0 2.5rem; }
.section    { padding: 7rem 0; }
.section-sm { padding: 4.5rem 0; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.85rem 2rem;
  font-family: var(--font-body); font-size: 0.8rem;
  font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  border-radius: var(--r);
  transition:
    transform 0.35s var(--ease-spring),
    box-shadow 0.3s var(--ease),
    background 0.25s,
    border-color 0.25s,
    color 0.25s;
  white-space: nowrap;
}
.btn-solid   { background: var(--blue); color: var(--white); }
.btn-solid:hover { background: var(--blue-mid); transform: translateY(-3px) scale(1.02); box-shadow: 0 10px 28px rgba(2,27,109,0.25); }
.btn-ghost   { border: 1.5px solid rgba(255,255,255,0.4); color: var(--white); }
.btn-ghost:hover  { background: rgba(255,255,255,0.12); border-color: rgba(255,255,255,0.75); transform: translateY(-2px); }
.btn-outline { border: 1.5px solid var(--blue); color: var(--blue); }
.btn-outline:hover { background: var(--blue); color: var(--white); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn-arrow::after { content: ' →'; display: inline-block; transition: transform 0.3s var(--ease-spring); }
.btn-arrow:hover::after { transform: translateX(5px); }

/* ---- Scroll Reveal ---- */
.sr {
  opacity: 0; transform: translateY(30px);
  transition: opacity 0.75s var(--ease-out), transform 0.75s var(--ease-out);
}
.sr.visible { opacity: 1; transform: none; }
.sr-left  { transform: translateX(-30px); }
.sr-right { transform: translateX(30px); }
.sr-left.visible, .sr-right.visible { transform: none; }
.sr-scale { transform: scale(0.93); }
.sr-scale.visible { transform: none; }

/* ============================================================
   NAVBAR
   ============================================================ */
.nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 1000; padding: 0 2.5rem;
  transition: background 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.nav.scrolled {
  background: rgba(3,11,52,0.96);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 4px 40px rgba(3,11,52,0.3);
}
.nav-inner {
  max-width: 1200px; margin: 0 auto;
  height: 76px; display: flex; align-items: center; justify-content: space-between;
}
.nav-logo { display: inline-flex; align-items: center; min-width: 0; }
.nav-logo img {
  height: 36px; width: auto;
  filter: brightness(0) invert(1);
  transition: transform 0.3s var(--ease-spring);
}
.nav-logo:hover img { transform: scale(1.05); }
.nav-links { display: flex; align-items: center; gap: 2.5rem; }
.nav-links a {
  font-size: 0.78rem; font-weight: 500;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: rgba(255,255,255,0.6);
  transition: color 0.25s; position: relative;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: -4px; left: 0;
  width: 0; height: 2px; background: var(--white); border-radius: 1px;
  transition: width 0.35s var(--ease-out);
}
.nav-links a:hover, .nav-links a.active { color: var(--white); }
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }
.nav-cta { flex-shrink: 0; }

.hamburger { display: none; flex-direction: column; justify-content: center; gap: 5px; padding: 6px; width: 36px; }
.hamburger span { display: block; height: 2px; background: var(--white); border-radius: 2px; transition: var(--trans); }
.hamburger span:nth-child(1) { width: 24px; }
.hamburger span:nth-child(2) { width: 16px; }
.hamburger span:nth-child(3) { width: 20px; }
.hamburger.open span:nth-child(1) { width: 24px; transform: rotate(45deg) translate(5px,5px); }
.hamburger.open span:nth-child(2) { opacity: 0; width: 0; }
.hamburger.open span:nth-child(3) { width: 24px; transform: rotate(-45deg) translate(5px,-5px); }

.mobile-nav {
  position: fixed; inset: 0; background: var(--blue-dark);
  z-index: 998;
  display: flex; flex-direction: column;
  justify-content: center; align-items: center; gap: 2rem;
  opacity: 0; pointer-events: none;
  overscroll-behavior: contain;
  transition: opacity 0.4s var(--ease);
}
.mobile-nav.open { opacity: 1; pointer-events: all; }
.mobile-nav a {
  font-family: var(--font-head); font-size: 2.2rem; font-weight: 700;
  color: rgba(255,255,255,0.7);
  transition: color 0.2s, transform 0.25s var(--ease-spring);
}
.mobile-nav a:hover { color: var(--white); transform: translateX(8px); }
.mobile-nav .btn { font-size: 0.85rem; margin-top: 1rem; }

/* ============================================================
   FOOTER
   ============================================================ */
footer {
  background: var(--blue-dark);
  padding: 5rem 0 2.5rem;
  border-top: 1px solid rgba(255,255,255,0.05);
}
.footer-top {
  display: grid;
  grid-template-columns: 1.8fr 1fr 1fr 1fr;
  gap: 4rem;
  padding-bottom: 4rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  margin-bottom: 2.5rem;
}
.footer-brand img  { height: 34px; filter: brightness(0) invert(1); margin-bottom: 1.5rem; }
.footer-brand p    { font-size: 0.85rem; color: rgba(255,255,255,0.32); line-height: 1.8; max-width: 280px; }
.footer-col h6     { font-size: 0.64rem; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: rgba(255,255,255,0.28); margin-bottom: 1.4rem; }
.footer-col a      { display: block; font-size: 0.85rem; color: rgba(255,255,255,0.45); padding: 0.3rem 0; transition: color 0.2s, padding-left 0.25s var(--ease-spring); }
.footer-col a:hover { color: var(--white); padding-left: 5px; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; font-size: 0.74rem; color: rgba(255,255,255,0.18); flex-wrap: wrap; gap: 1rem; }
.footer-bottom a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.footer-bottom a:hover { color: var(--white); }

/* ============================================================
   PAGE HERO
   ============================================================ */
.page-hero {
  background: var(--blue-dark);
  padding: 11rem 0 6rem;
  position: relative; overflow: hidden;
}
.page-hero-bg {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 70% 80% at 80% 50%, rgba(2,27,109,0.5) 0%, transparent 70%);
}
.page-hero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 80px 80px;
}
.page-hero .container { position: relative; }
.breadcrumb { display: flex; align-items: center; gap: 0.5rem; font-size: 0.72rem; color: rgba(255,255,255,0.28); margin-bottom: 2rem; }
.breadcrumb a { color: rgba(255,255,255,0.5); transition: color 0.2s; }
.breadcrumb a:hover { color: var(--white); }
.breadcrumb span { color: rgba(255,255,255,0.16); }
.page-hero h1 { color: var(--white); margin-bottom: 1.2rem; max-width: 700px; }
.page-hero p  { color: rgba(255,255,255,0.48); font-size: 1.05rem; max-width: 480px; }

/* ============================================================
   FORMS
   ============================================================ */
.form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.field { display: flex; flex-direction: column; gap: 0.4rem; }
.field label { font-size: 0.7rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--silver-dim); }
.field input, .field select, .field textarea {
  padding: 0.85rem 1.1rem;
  border: 1.5px solid var(--border); border-radius: var(--r);
  font-size: 0.95rem; color: var(--blue-dark); background: var(--white);
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.2s var(--ease-spring);
  outline: none; width: 100%; appearance: none;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(2,27,109,0.06);
  transform: translateY(-1px);
}
.field textarea { resize: vertical; min-height: 120px; }
.form-status { padding: 0.9rem 1.1rem; border-radius: var(--r); font-size: 0.88rem; font-weight: 500; display: none; }
.form-status.success { background: #e8f5e9; color: #2e7d32; border: 1px solid #c8e6c9; display: block; }
.form-status.error   { background: #fce4ec; color: #c62828; border: 1px solid #f8bbd0; display: block; }

/* ============================================================
   PRODUCT CARDS
   ============================================================ */
.product-card {
  background: var(--white); border-radius: var(--r-lg);
  overflow: hidden; border: 1px solid var(--border);
  transition: transform 0.4s var(--ease-spring), box-shadow 0.4s var(--ease), border-color 0.3s;
  display: flex; flex-direction: column;
}
.product-card:hover { transform: translateY(-10px) scale(1.01); box-shadow: var(--shadow-lg); border-color: transparent; }
.product-card-img { width: 100%; aspect-ratio: 1; object-fit: cover; background: var(--off-white); transition: transform 0.6s var(--ease); }
.product-card:hover .product-card-img { transform: scale(1.06); }
.product-card-img-wrap { overflow: hidden; }
.product-card-body { padding: 1.3rem 1.4rem 1.5rem; flex: 1; display: flex; flex-direction: column; gap: 0.4rem; }
.product-cat-tag { font-size: 0.62rem; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: var(--blue); }
.product-card-body h3 { font-size: 0.95rem; font-weight: 700; color: var(--blue-dark); }
.product-card-body p  { font-size: 0.8rem; line-height: 1.6; flex: 1; }
.product-card-body .btn { align-self: flex-start; padding: 0.5rem 1.1rem; font-size: 0.7rem; margin-top: 0.5rem; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .footer-top { grid-template-columns: 1fr 1fr; gap: 2.5rem; }
}
@media (max-width: 768px) {
  .nav { padding: 0 1rem; }
  .sr, .sr-left, .sr-right, .sr-scale {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .nav-links, .nav-cta { display: none; }
  .hamburger { display: flex; }
  .mobile-nav {
    justify-content: flex-start;
    align-items: stretch;
    gap: 1rem;
    padding: calc(6.5rem + env(safe-area-inset-top, 0px)) 1.5rem 2rem;
    overflow-y: auto;
  }
  .mobile-nav a {
    font-size: 1.7rem;
    text-align: left;
  }
  .mobile-nav .btn {
    justify-content: center;
    margin-top: 0.5rem;
  }
  .section { padding: 5rem 0; }
  .page-hero { padding: 8rem 0 4rem; }
  .container, .container-wide { padding: 0 1.5rem; }
  .form-grid-2 { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; gap: 2rem; }
  .footer-brand p { max-width: none; }
  .footer-bottom { flex-direction: column; text-align: center; }
}
@media (max-width: 560px) {
  .page-hero { padding: 7.25rem 0 3.5rem; }
  .page-hero p { font-size: 0.98rem; }
  .breadcrumb { flex-wrap: wrap; row-gap: 0.25rem; }
  .btn {
    width: 100%;
    min-height: 48px;
    justify-content: center;
    text-align: center;
    white-space: normal;
    line-height: 1.4;
  }
}
@media (max-width: 480px) {
  h1 { font-size: 2.3rem; }
  h2 { font-size: 1.75rem; }
}


/* ---- Accessibility + performance refinements ---- */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  z-index: 2000;
  background: var(--white);
  color: var(--blue-dark);
  padding: 0.75rem 1rem;
  border-radius: var(--r);
  box-shadow: var(--shadow-md);
  font-weight: 600;
}
.skip-link:focus {
  top: 1rem;
}
:focus-visible {
  outline: 3px solid rgba(26,59,181,0.35);
  outline-offset: 3px;
}
.nav a:focus-visible,
.btn:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(26,59,181,0.35);
  outline-offset: 3px;
}
img[aria-hidden="true"] { pointer-events: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
