/* ============================================================
   Let Us Care — Shared stylesheet
   Brand: warm, trustworthy healthcare
   Palette sourced from LUCS_Logo_Reference_sheet.png
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Birthstone&display=swap');

:root {
  /* Brand palette — exact codes from official LUCS brand reference sheet */
  --brand-primary:       #0669ab;   /* deep blue — wordmark, hands */
  --brand-primary-dark:  #054b7d;   /* deeper blue for hovers */
  --brand-primary-light: #4c7cb3;   /* medium blue — secondary */
  --brand-primary-50:    #E6F0F8;   /* soft blue tint for backgrounds */
  --brand-accent:        #c42527;   /* deep red — heart */
  --brand-accent-dark:   #9a1d1f;   /* darker red for hovers */
  --brand-accent-bright: #dc3F45;   /* bright red — highlights/CTAs */
  --brand-accent-50:     #FAEAEA;   /* soft red tint */
  --brand-cream:         #EFF5FA;   /* page-soft tint */
  --ink-900: #14223A;
  --ink-700: #3A4860;
  --ink-500: #6B7A92;
  --ink-300: #B8C2D2;
  --ink-100: #E5EAF2;
  --bg: #ffffff;
  --bg-soft: #F6F9FD;
  --success: #2E8B57;
  --warning: #D97706;
  --danger:  #9a1d1f;
  --radius: 10px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --shadow-md: 0 6px 18px rgba(0,0,0,.08);
  --shadow-lg: 0 20px 45px rgba(0,0,0,.12);
  --font-sans:    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: "Inter", Georgia, serif;
  --font-script:  "Birthstone", "Brush Script MT", cursive;  /* brand wordmark font */
  --max-width: 1180px;
}

/* Use this class to render text in the Birthstone brand script.
   Use sparingly — only for decorative tagline / section flourishes.
   The logo image already renders "Let us care" in Birthstone. */
.brand-script {
  font-family: var(--font-script);
  font-weight: 400;
  line-height: 1;
  color: var(--brand-primary);
}

* { box-sizing: border-box; }

html, body {
  margin: 0; padding: 0;
  font-family: var(--font-sans);
  color: var(--ink-900);
  background: var(--bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--brand-primary); text-decoration: none; }
a:hover { color: var(--brand-primary-dark); text-decoration: underline; }

img { max-width: 100%; display: block; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--ink-900);
  letter-spacing: -.01em;
  line-height: 1.2;
  margin: 0 0 .5em;
}

h1 { font-size: clamp(2rem, 4vw, 3rem); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); font-weight: 700; }
h3 { font-size: 1.25rem; font-weight: 600; }

p { margin: 0 0 1em; color: var(--ink-700); }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------------- Header ---------------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.94);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--ink-100);
}
.site-header .nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 0;
  min-height: 140px;
}
.brand {
  display: flex; align-items: center; gap: 12px;
  font-weight: 700; font-size: 1.05rem; color: var(--ink-900);
  line-height: 1;
}
.brand img {
  height: 120px; width: auto; display: block;
  filter: drop-shadow(0 1px 1px rgba(0,0,0,.04));
}
.brand-mark { /* legacy fallback only */
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-accent));
  display: grid; place-items: center; color: #fff; font-weight: 800;
}
.brand:hover { text-decoration: none; }
.site-footer .brand img {
  height: 96px; background: #fff; padding: 10px 16px;
  border-radius: 12px; box-shadow: var(--shadow-sm);
}
.portal-sidebar .brand img { height: 72px; }
@media (max-width: 900px) {
  .brand img { height: 96px; }
  .site-header .nav { min-height: 112px; }
}
@media (max-width: 600px) {
  .brand img { height: 72px; }
  .site-header .nav { min-height: 92px; }
}
.nav-links {
  display: flex; gap: 28px; align-items: center;
  list-style: none; margin: 0; padding: 0;
}
.nav-links a {
  color: var(--ink-700); font-weight: 500; font-size: .96rem;
}
.nav-links a.active, .nav-links a:hover { color: var(--brand-primary); text-decoration: none; }
.nav-cta {
  background: var(--brand-primary); color: #fff !important;
  padding: 9px 18px; border-radius: 999px; font-weight: 600;
}
.nav-cta:hover { background: var(--brand-primary-dark); }

.menu-toggle { display: none; background: none; border: 0; padding: 6px; cursor: pointer; }
.menu-toggle span { display: block; width: 24px; height: 2px; background: var(--ink-900); margin: 5px 0; }

/* ---------------- Buttons ---------------- */
.btn {
  display: inline-block; cursor: pointer; border: 0;
  padding: 12px 22px; border-radius: 999px;
  font-weight: 600; font-size: 1rem;
  transition: transform .08s ease, background .2s ease, color .2s ease, box-shadow .2s ease;
  text-decoration: none;
}
.btn:hover { transform: translateY(-1px); text-decoration: none; }
.btn-primary { background: var(--brand-primary); color: #fff; }
.btn-primary:hover { background: var(--brand-primary-dark); color: #fff; }
.btn-accent  { background: var(--brand-accent); color: #fff; }
.btn-accent:hover { background: var(--brand-accent-dark); color: #fff; }
.btn-outline { background: transparent; color: var(--brand-primary); box-shadow: inset 0 0 0 2px var(--brand-primary); }
.btn-outline:hover { background: var(--brand-primary); color: #fff; }
.btn-ghost { background: transparent; color: var(--ink-700); }
.btn-ghost:hover { color: var(--brand-primary); background: var(--ink-100); }
.btn-sm { padding: 7px 14px; font-size: .9rem; }
.btn-block { display: block; width: 100%; text-align: center; }

/* ---------------- Hero ---------------- */
.hero {
  background:
    radial-gradient(1200px 500px at 80% -10%, rgba(234,24,63,.10), transparent),
    radial-gradient(900px 500px at -10% 30%, rgba(67,135,234,.12), transparent),
    linear-gradient(180deg, var(--brand-cream) 0%, #ffffff 100%);
  padding: 80px 0 96px;
}
.hero-grid {
  display: grid; grid-template-columns: 1.1fr .9fr; gap: 60px; align-items: center;
}
.eyebrow {
  display: inline-block;
  background: var(--brand-accent-50); color: var(--brand-accent-dark);
  padding: 6px 14px; border-radius: 999px;
  font-size: .85rem; font-weight: 600; letter-spacing: .02em;
  margin-bottom: 18px;
}
.hero h1 { margin-bottom: 18px; }
.hero p.lede {
  font-size: 1.15rem; color: var(--ink-700); max-width: 540px;
}
.hero-cta { display: flex; gap: 14px; margin-top: 28px; flex-wrap: wrap; }
.hero-card {
  background: #fff; border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 28px;
  border: 1px solid var(--ink-100);
}
.hero-card h3 { margin-bottom: 6px; }
.stat-row { display: flex; gap: 24px; margin-top: 22px; }
.stat { flex: 1; }
.stat strong {
  display: block; font-size: 1.6rem; color: var(--brand-primary); font-weight: 700;
}
.stat span { color: var(--ink-500); font-size: .9rem; }

/* ---------------- Sections ---------------- */
.section { padding: 80px 0; }
.section-soft { background: var(--bg-soft); }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 50px; }
.section-head p { color: var(--ink-500); }

/* ---------------- Cards / Grids ---------------- */
.card-grid {
  display: grid; gap: 24px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.card {
  background: #fff; border: 1px solid var(--ink-100);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: rgba(67,135,234,.35); }
.card .icon {
  width: 52px; height: 52px; border-radius: 14px;
  background: linear-gradient(135deg, var(--brand-primary-50), var(--brand-accent-50));
  color: var(--brand-primary);
  display: grid; place-items: center; margin-bottom: 16px;
  font-size: 1.5rem;
}
.card h3 { margin-bottom: 8px; }
.card p { color: var(--ink-700); font-size: .95rem; }

/* ---------------- Footer ---------------- */
.site-footer {
  background: linear-gradient(180deg, #14223A 0%, #0E1A2E 100%);
  color: #B8C2D2;
  padding: 60px 0 30px; margin-top: 80px;
}
.site-footer h4 { color: #fff; font-size: 1rem; margin-bottom: 14px; }
.footer-grid {
  display: grid; gap: 40px;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  margin-bottom: 40px;
}
.site-footer a { color: #cdd6d8; }
.site-footer a:hover { color: #fff; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer ul li { margin-bottom: 8px; font-size: .92rem; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 20px;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  color: #97a3a6; font-size: .88rem;
}

/* ---------------- Forms ---------------- */
.form-group { margin-bottom: 18px; }
.form-group label {
  display: block; font-weight: 600; font-size: .9rem;
  color: var(--ink-700); margin-bottom: 6px;
}
.form-control {
  width: 100%; padding: 12px 14px;
  border: 1px solid var(--ink-300); border-radius: var(--radius);
  font-family: inherit; font-size: 1rem; color: var(--ink-900);
  background: #fff;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.form-control:focus {
  outline: none; border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(67,135,234,.18);
}
textarea.form-control { resize: vertical; min-height: 120px; }
.form-row { display: grid; gap: 16px; grid-template-columns: 1fr 1fr; }
.form-help { font-size: .85rem; color: var(--ink-500); margin-top: 4px; }
.form-status {
  padding: 10px 14px; border-radius: var(--radius);
  font-size: .9rem; margin-top: 10px; display: none;
}
.form-status.error { background: #fdecea; color: var(--danger); display: block; }
.form-status.success { background: #e6f4ec; color: var(--success); display: block; }

/* ---------------- Auth (login) page ---------------- */
.auth-page {
  min-height: calc(100vh - 80px);
  display: grid; grid-template-columns: 1fr 1fr;
}
.auth-side {
  background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-primary-dark) 70%, #1A3F7E 100%);
  color: #fff;
  padding: 60px;
  display: flex; flex-direction: column; justify-content: center;
  position: relative; overflow: hidden;
}
.auth-side::after {
  content: ""; position: absolute; right: -80px; bottom: -80px;
  width: 280px; height: 280px; border-radius: 50%;
  background: radial-gradient(circle, rgba(234,24,63,.35), transparent 60%);
  pointer-events: none;
}
.auth-side h2 { color: #fff; }
.auth-side p { color: rgba(255,255,255,.85); }
.auth-side ul { list-style: none; padding: 0; margin: 24px 0 0; }
.auth-side ul li {
  padding: 10px 0 10px 28px; position: relative; color: rgba(255,255,255,.9);
}
.auth-side ul li::before {
  content: "✓"; position: absolute; left: 0; top: 8px;
  color: var(--brand-accent); font-weight: 700;
}
.auth-form-wrap {
  padding: 60px; display: flex; flex-direction: column; justify-content: center;
  max-width: 520px; width: 100%; margin: 0 auto;
}
.role-tabs {
  display: flex; background: var(--ink-100); border-radius: 999px;
  padding: 4px; margin-bottom: 28px;
}
.role-tabs button {
  flex: 1; border: 0; background: transparent;
  padding: 10px 16px; border-radius: 999px;
  font-weight: 600; cursor: pointer; color: var(--ink-700);
  font-size: .95rem; transition: all .15s ease;
}
.role-tabs button.active {
  background: #fff; color: var(--brand-primary); box-shadow: var(--shadow-sm);
}
.role-tabs button[data-role="employee"].active { color: var(--brand-accent-dark); }

/* ---------------- Portal layout ---------------- */
.portal {
  display: grid; grid-template-columns: 260px 1fr;
  min-height: 100vh;
  background: var(--bg-soft);
}
.portal-sidebar {
  background: #fff; border-right: 1px solid var(--ink-100);
  padding: 24px 0; position: sticky; top: 0; height: 100vh;
  display: flex; flex-direction: column;
}
.portal-sidebar .brand { padding: 0 24px 24px; border-bottom: 1px solid var(--ink-100); }
.portal-nav { list-style: none; padding: 16px 0; margin: 0; flex: 1; }
.portal-nav li a {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 24px;
  color: var(--ink-700); font-weight: 500;
  border-left: 3px solid transparent;
}
.portal-nav li a:hover { background: var(--bg-soft); color: var(--brand-primary); text-decoration: none; }
.portal-nav li a.active {
  color: var(--brand-primary); background: var(--brand-primary-50);
  border-left-color: var(--brand-primary);
}
.portal-nav .nav-icon { width: 18px; display: inline-grid; place-items: center; font-size: 1rem; }

.portal-main { padding: 32px 40px 60px; max-width: 1100px; }
.portal-topbar {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 28px;
}
.portal-topbar h1 { font-size: 1.7rem; margin: 0; }
.user-chip {
  display: flex; align-items: center; gap: 10px;
  background: #fff; padding: 6px 14px 6px 6px; border-radius: 999px;
  box-shadow: var(--shadow-sm); border: 1px solid var(--ink-100);
}
.user-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--brand-primary); color: #fff;
  display: grid; place-items: center; font-weight: 700; font-size: .85rem;
}

/* ---------------- Portal widgets ---------------- */
.stat-grid {
  display: grid; gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  margin-bottom: 28px;
}
.stat-card {
  background: #fff; padding: 22px; border-radius: var(--radius-lg);
  border: 1px solid var(--ink-100);
}
.stat-card .label { font-size: .85rem; color: var(--ink-500); text-transform: uppercase; letter-spacing: .04em; margin-bottom: 6px; }
.stat-card .value { font-size: 1.8rem; font-weight: 700; color: var(--ink-900); }
.stat-card .delta { font-size: .85rem; margin-top: 4px; color: var(--ink-500); }
.stat-card .delta.up { color: var(--success); }
.stat-card .delta.down { color: var(--danger); }

.panel {
  background: #fff; border: 1px solid var(--ink-100);
  border-radius: var(--radius-lg); padding: 24px;
  margin-bottom: 22px;
}
.panel-head {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 16px;
}
.panel-head h2 { font-size: 1.1rem; margin: 0; }

.table { width: 100%; border-collapse: collapse; }
.table th, .table td {
  text-align: left; padding: 12px 10px;
  border-bottom: 1px solid var(--ink-100);
  font-size: .94rem;
}
.table th { color: var(--ink-500); font-weight: 600; font-size: .82rem; text-transform: uppercase; letter-spacing: .04em; }

.badge {
  display: inline-block; padding: 3px 10px; border-radius: 999px;
  font-size: .8rem; font-weight: 600;
}
.badge.success { background: #e6f4ec; color: var(--success); }
.badge.warning { background: #fef3e6; color: var(--warning); }
.badge.danger  { background: #fdecea; color: var(--danger); }
.badge.info    { background: var(--brand-primary-50); color: var(--brand-primary-dark); }
.badge.neutral { background: var(--ink-100); color: var(--ink-700); }

/* ---------------- Photo blocks ---------------- */
.photo {
  position: relative; border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-md);
  background: var(--bg-soft);
}
.photo img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform .5s ease;
}
.photo:hover img { transform: scale(1.03); }
.photo-caption {
  position: absolute; left: 18px; bottom: 18px; right: 18px;
  color: #fff; font-size: .9rem; font-weight: 500;
  text-shadow: 0 1px 4px rgba(0,0,0,.6);
}
.photo-grid {
  display: grid; gap: 18px;
  grid-template-columns: repeat(3, 1fr);
}
.photo-grid .photo { aspect-ratio: 4/3; }
@media (max-width: 800px) { .photo-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .photo-grid { grid-template-columns: 1fr; } }

.hero-photo {
  border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4/5; max-height: 540px;
  position: relative;
  border: 6px solid #fff;
}
.hero-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-photo::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(20,34,58,.5) 100%);
  z-index: 1; pointer-events: none;
}

.feature-photo {
  border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-md);
  aspect-ratio: 16/10;
}
.feature-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Card with a photo at the top */
.card-photo {
  background: #fff; border: 1px solid var(--ink-100);
  border-radius: var(--radius-lg); overflow: hidden;
  transition: transform .15s ease, box-shadow .15s ease;
}
.card-photo:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.card-photo .photo-top { aspect-ratio: 16/10; overflow: hidden; }
.card-photo .photo-top img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease; }
.card-photo:hover .photo-top img { transform: scale(1.04); }
.card-photo .body { padding: 22px; }
.card-photo h3 { margin-bottom: 6px; }
.card-photo p { color: var(--ink-700); font-size: .95rem; margin: 0; }

/* ---------------- CTA banner ---------------- */
.cta-banner {
  background:
    radial-gradient(600px 300px at 90% 110%, rgba(234,24,63,.4), transparent 60%),
    linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-primary-dark) 60%, #1A3F7E 100%);
  color: #fff; padding: 70px 40px; border-radius: var(--radius-lg);
  text-align: center; position: relative; overflow: hidden;
}
.cta-banner h2 { color: #fff; }
.cta-banner p { color: rgba(255,255,255,.85); max-width: 600px; margin: 0 auto 22px; }

/* ---------------- Utilities ---------------- */
.muted { color: var(--ink-500); }
.text-center { text-align: center; }
.mt-0 { margin-top: 0; } .mt-1 { margin-top: 8px; } .mt-2 { margin-top: 16px; } .mt-3 { margin-top: 24px; }
.mb-0 { margin-bottom: 0; } .mb-1 { margin-bottom: 8px; } .mb-2 { margin-bottom: 16px; } .mb-3 { margin-bottom: 24px; }
.hidden { display: none !important; }

/* ---------------- Responsive ---------------- */
@media (max-width: 900px) {
  .hero-grid, .footer-grid { grid-template-columns: 1fr; gap: 30px; }
  .form-row { grid-template-columns: 1fr; }
  .auth-page { grid-template-columns: 1fr; min-height: auto; }
  .auth-side { padding: 40px 24px; }
  .auth-form-wrap { padding: 40px 24px; }
  .portal { grid-template-columns: 1fr; }
  .portal-sidebar {
    position: relative; height: auto;
    border-right: 0; border-bottom: 1px solid var(--ink-100);
  }
  .portal-nav { display: flex; overflow-x: auto; padding: 8px 12px; }
  .portal-nav li a { border-left: 0; border-bottom: 3px solid transparent; white-space: nowrap; padding: 10px 14px; }
  .portal-nav li a.active { border-left: 0; border-bottom-color: var(--brand-primary); }
  .portal-main { padding: 24px 20px; }
  .menu-toggle { display: block; }
  .nav-links {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; flex-direction: column; align-items: stretch;
    padding: 12px 24px; gap: 0; border-bottom: 1px solid var(--ink-100);
  }
  .nav-links.open { display: flex; }
  .nav-links li { padding: 10px 0; border-bottom: 1px solid var(--ink-100); }
  .nav-links li:last-child { border-bottom: 0; }
}
