@import url('premium-components.css');
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/all.min.css');

/* FitFlow Premium Component Layer
   Shared presentation only: no application logic or layout dependencies.
   Reusable foundation lives in design-system.css; this file adds FitFlow-specific components.
*/
:root {
  --primary: #0f9b8e;
  --primary-dark: #087f75;
  --primary-light: #e6faf7;
  --accent: #34d399;
  --accent-soft: #ecfdf5;
  --ink: #102a2b;
  --text: #294344;
  --text-muted: #6b7f80;
  --surface: #ffffff;
  --surface-soft: #f5faf9;
  --border: #dcebea;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --shadow-sm: 0 2px 10px rgba(16, 42, 43, 0.06);
  --shadow-md: 0 12px 32px rgba(16, 42, 43, 0.10);
  --shadow-lg: 0 24px 60px rgba(16, 42, 43, 0.14);
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --transition: 180ms cubic-bezier(.2,.7,.2,1);
}

html { scroll-behavior: smooth; }
body { font-family: var(--font-sans); color: var(--text); background: #f7fbfa; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: hidden; }
button, a, input, select, textarea { font: inherit; }
img, svg, video, canvas { max-width: 100%; }
:focus-visible { outline: 3px solid rgba(52, 211, 153, .45); outline-offset: 3px; }

header {
  position: sticky; top: 0; z-index: 1000; display: flex; align-items: center; justify-content: space-between; gap: 24px;
  min-height: 76px; padding: 10px clamp(18px, 4vw, 48px); color: #fff; background: rgba(10, 73, 69, .94);
  border-bottom: 1px solid rgba(255,255,255,.12); box-shadow: 0 8px 30px rgba(5, 52, 49, .12);
  backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%);
}
.logo { display: flex; align-items: center; flex: 0 0 auto; }
.logo img { width: 52px; height: 52px; object-fit: cover; border-radius: 15px; box-shadow: 0 8px 20px rgba(0,0,0,.16); transition: transform var(--transition), box-shadow var(--transition); }
.logo img:hover { transform: translateY(-2px) rotate(2deg); box-shadow: 0 12px 26px rgba(0,0,0,.2); }
.name { display: flex; flex-direction: column; justify-content: center; margin-right: auto; }
.name h1 { margin: 0; color: #fff; font-size: clamp(1.1rem, 1.6vw, 1.45rem); font-weight: 800; letter-spacing: .12em; }
.name p { margin: 2px 0 0; color: rgba(230,250,247,.78); font-size: .72rem; letter-spacing: .04em; }
nav { display: flex; align-items: center; }
nav ul { display: flex; align-items: center; gap: 4px; margin: 0; padding: 0; list-style: none; }
nav ul li a { position: relative; display: inline-flex; align-items: center; gap: 7px; min-height: 42px; padding: 9px 12px; color: rgba(255,255,255,.84); text-decoration: none; font-size: .84rem; font-weight: 650; border: 1px solid transparent; border-radius: 12px; transition: background var(--transition), color var(--transition), transform var(--transition), border-color var(--transition); }
nav ul li a:hover { color: #fff; background: rgba(255,255,255,.10); border-color: rgba(255,255,255,.10); transform: translateY(-1px); }
nav ul li a:active { transform: translateY(0); }
nav ul li a i { color: rgba(167,243,208,.92); }
.menu-toggle { display: none; padding: 9px 11px; color: #fff; font-size: 1.35rem; line-height: 1; cursor: pointer; border: 1px solid rgba(255,255,255,.14); border-radius: 12px; background: rgba(255,255,255,.08); }
.custom-tooltip { position: absolute; z-index: 10001; padding: 7px 10px; color: #fff; background: #153b3c; border-radius: 9px; box-shadow: var(--shadow-md); font-size: .75rem; }
#tooltip { display: none; position: absolute; top: calc(100% + 10px); right: 18px; width: min(280px, calc(100vw - 36px)); height: auto; margin: 0; padding: 8px; overflow: hidden; background: rgba(11, 56, 54, .98); border: 1px solid rgba(255,255,255,.12); border-radius: 16px; box-shadow: var(--shadow-lg); z-index: 1001; }
#tooltip ol { margin: 0; padding: 0; list-style: none; }
#tooltip li { display: block; }
#tooltip a { display: flex; align-items: center; gap: 10px; padding: 11px 12px; color: rgba(255,255,255,.88); text-decoration: none; border-radius: 10px; }
#tooltip a:hover { color: #fff; background: rgba(255,255,255,.09); }
#tooltip a i { width: 18px; color: #86efac; text-align: center; }
.cta-button { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 11px 18px; color: #fff; background: linear-gradient(135deg, var(--primary), #0b857b); border: 1px solid rgba(255,255,255,.12); border-radius: 13px; box-shadow: 0 10px 24px rgba(15,155,142,.22); cursor: pointer; text-decoration: none; font-weight: 750; transition: transform var(--transition), box-shadow var(--transition), filter var(--transition); }
.cta-button:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(15,155,142,.28); filter: saturate(1.08); }
.cta-button:active { transform: translateY(0); }
.modal { display: none; position: fixed; inset: 0; z-index: 9999; align-items: center; justify-content: center; padding: 20px; background: rgba(7,31,31,.58); backdrop-filter: blur(8px); }
.modal-content { position: relative; width: min(440px,100%); padding: 30px; color: var(--text); background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-xl); box-shadow: var(--shadow-lg); text-align: center; max-height: 88vh; overflow-y: auto; }
.modal-content h2 { margin: 0 0 10px; color: var(--ink); font-size: 1.5rem; }
.modal-content p { margin: 0 0 20px; color: var(--text-muted); }
.close-btn { position: absolute; top: 12px; right: 16px; color: #7b9090; font-size: 1.5rem; cursor: pointer; }
.close-btn:hover { color: var(--ink); }

main, section, article, .container, .content, .login-container, .signup-container, .form-container, .contact-container { min-width: 0; max-width: 100%; }
input, select, textarea, button { max-width: 100%; }
form { max-width: 100%; }

@media (max-width:1120px) {
  header { gap: 14px; }
  nav ul { gap: 1px; }
  nav ul li a { padding: 8px 9px; font-size: .78rem; }
  .name p { display:none; }
}
@media (max-width:900px) {
  section { padding-inline: clamp(18px, 4vw, 32px); }
  .enhanced-hero { min-height: auto; padding-block: clamp(56px, 10vw, 88px); gap: 34px; }
  .hero-content h1 { font-size: clamp(2.2rem, 7vw, 3.4rem); }
  .hero-content p { font-size: clamp(1rem, 2.4vw, 1.2rem); }
  .stats-card { width: calc(50% - 10px); }
  .features-container { gap: 18px; }
  .feature-card { width: calc(50% - 10px); min-width: 0; }
}
@media (max-width:820px) {
  header { min-height:68px; padding:8px 16px; }
  .logo img { width:46px; height:46px; }
  .menu-toggle { display:inline-flex; }
  nav ul { display:none; position:absolute; top:calc(100% + 8px); left:14px; right:14px; flex-direction:column; align-items:stretch; gap:4px; padding:9px; background:rgba(11,56,54,.98); border:1px solid rgba(255,255,255,.12); border-radius:16px; box-shadow:var(--shadow-lg); }
  nav ul.show, header nav.active ul { display:flex; }
  nav ul li a { justify-content:flex-start; width:100%; min-height:46px; }
  .hero-visual { width:100%; }
  .enhanced-hero { flex-direction: column; align-items: stretch; text-align: center; }
  .hero-buttons { justify-content:center; }
  .hero-content { max-width:none; }
  .features-container { grid-template-columns: 1fr; }
  .feature-card { width:100%; min-height:260px; height:auto; }
}
@media (max-width:600px) {
  section { padding: 56px 16px; }
  .name h1 { font-size: 1rem; letter-spacing: .09em; }
  .hero-content h1 { font-size: clamp(1.9rem, 10vw, 2.6rem); line-height:1.1; }
  .hero-content p { font-size: .98rem; }
  .hero-buttons { flex-direction:column; align-items:stretch; }
  .hero-buttons .cta-button { width:100%; }
  .stats-card { width:100%; }
  .feature-card { width:100%; }
  .section-header h2 { font-size: clamp(1.7rem, 8vw, 2.25rem); }
  .modal { padding:10px; }
  .modal-content { padding:22px 18px; border-radius:20px; }
}
@media (max-width:380px) {
  header { padding-inline:10px; }
  .logo img { width:42px; height:42px; }
  .name h1 { font-size:.9rem; }
  section { padding-inline:12px; }
  .menu-toggle { padding:8px 9px; }
}
@media (prefers-reduced-motion:reduce) {
  html { scroll-behavior:auto; }
  *,*::before,*::after { animation-duration:.01ms !important; animation-iteration-count:1 !important; transition-duration:.01ms !important; }
}

/*
 * Public navbar contract
 * ----------------------
 * Public pages historically had page-level rules targeting the bare <header>,
 * <nav>, and <nav> ul selectors. Those rules could change the shared navbar's
 * dimensions depending on which page stylesheet loaded last. The public shell
 * is always a direct child of <body>, so this stronger selector intentionally
 * owns its geometry without affecting the authenticated dashboard header.
 */
body > header {
  box-sizing: border-box !important;
  width: 100% !important;
  height: 76px !important;
  min-height: 76px !important;
  max-height: 76px !important;
  margin: 0 !important;
  padding: 10px clamp(18px, 4vw, 48px) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 24px !important;
  position: sticky !important;
  top: 0 !important;
  z-index: 1000 !important;
  overflow: visible !important;
}
body > header .logo {
  flex: 0 0 auto !important;
  width: auto !important;
  height: 52px !important;
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
  align-items: center !important;
}
body > header .logo img {
  width: 52px !important;
  height: 52px !important;
  min-width: 52px !important;
  max-width: 52px !important;
  object-fit: cover !important;
  margin: 0 !important;
}
body > header .name {
  flex: 1 1 auto !important;
  min-width: 0 !important;
  width: auto !important;
  height: auto !important;
  margin: 0 auto 0 0 !important;
  padding: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
}
body > header .name h1,
body > header .name p {
  width: auto !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
}
body > header nav {
  flex: 0 0 auto !important;
  width: auto !important;
  height: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
  align-items: center !important;
  position: relative !important;
}
body > header nav ul {
  width: auto !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 4px !important;
  list-style: none !important;
}
body > header nav ul li {
  width: auto !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  display: block !important;
}
body > header nav ul li a {
  box-sizing: border-box !important;
  width: auto !important;
  height: 42px !important;
  min-height: 42px !important;
  max-height: 42px !important;
  margin: 0 !important;
  padding: 9px 12px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  white-space: nowrap !important;
}
body > header .menu-toggle {
  box-sizing: border-box !important;
  width: 44px !important;
  height: 44px !important;
  min-width: 44px !important;
  min-height: 44px !important;
  max-width: 44px !important;
  max-height: 44px !important;
  margin: 0 !important;
  padding: 9px 11px !important;
  align-items: center !important;
  justify-content: center !important;
}

@media (max-width:1120px) {
  body > header { gap: 14px !important; }
  body > header nav ul { gap: 1px !important; }
  body > header nav ul li a { height: 40px !important; min-height: 40px !important; max-height: 40px !important; padding: 8px 9px !important; font-size: .78rem !important; }
}
@media (max-width:820px) {
  body > header {
    height: 68px !important;
    min-height: 68px !important;
    max-height: 68px !important;
    padding: 8px 16px !important;
  }
  body > header .logo,
  body > header .logo img { width: 46px !important; height: 46px !important; min-width: 46px !important; max-width: 46px !important; }
  body > header .name { flex: 1 1 auto !important; }
  body > header nav ul {
    display: none !important;
    position: absolute !important;
    top: calc(100% + 8px) !important;
    left: auto !important;
    right: 0 !important;
    width: min(320px, calc(100vw - 28px)) !important;
    height: auto !important;
    max-height: calc(100vh - 82px) !important;
    overflow-y: auto !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    gap: 4px !important;
    padding: 9px !important;
    box-sizing: border-box !important;
  }
  body > header nav ul.show,
  body > header nav.active ul,
  body > header nav ul.is-open { display: flex !important; }
  body > header nav ul li,
  body > header nav ul li a { width: 100% !important; }
  body > header nav ul li a {
    height: 46px !important;
    min-height: 46px !important;
    max-height: 46px !important;
    justify-content: flex-start !important;
    padding: 11px 12px !important;
  }
  body > header .menu-toggle { display: inline-flex !important; }
}
@media (max-width:600px) {
  body > header { padding-inline: 12px !important; }
  body > header .name h1 { font-size: 1rem !important; }
}
@media (max-width:380px) {
  body > header { padding-inline: 10px !important; }
  body > header .logo,
  body > header .logo img { width: 42px !important; height: 42px !important; min-width: 42px !important; max-width: 42px !important; }
  body > header .name h1 { font-size: .9rem !important; }
  body > header .menu-toggle { width: 42px !important; height: 42px !important; min-width: 42px !important; min-height: 42px !important; }
}
