/* Lift Shop Customer Portal — Global Styles */
:root {
  --navy: #1a1a2e;
  --navy-light: #16213e;
  --navy-dark: #0f0f23;
  --accent: #3a86ff;
  --accent-hover: #2d6fd6;
  --white: #ffffff;
  --grey-50: #f8f9fa;
  --grey-100: #f0f2f5;
  --grey-200: #e2e6ea;
  --grey-300: #d1d5db;
  --grey-600: #6b7280;
  --grey-700: #4b5563;
  --green: #10b981;
  --green-bg: #ecfdf5;
  --orange: #f59e0b;
  --orange-bg: #fffbeb;
  --red: #ef4444;
  --red-bg: #fef2f2;
  --shadow-sm: 0 1px 3px rgba(0,0,0,.08);
  --shadow-md: 0 4px 12px rgba(0,0,0,.1);
  --shadow-lg: 0 8px 30px rgba(0,0,0,.12);
  --radius: 12px;
  --radius-sm: 8px;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, sans-serif;
  background: var(--grey-100);
  color: var(--navy);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.6;
}

/* ── NAV ───────────────────────────────────── */
nav {
  background: var(--navy);
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,.2);
}
.nav-brand {
  color: var(--white);
  font-weight: 800;
  font-size: 1.2rem;
  letter-spacing: 2px;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}
.nav-brand span.icon { font-size: 1.4rem; }
.nav-links { display: flex; gap: 4px; align-items: center; }
.nav-links a {
  color: rgba(255,255,255,.75);
  text-decoration: none;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  font-size: .875rem;
  font-weight: 500;
  transition: all .2s;
}
.nav-links a:hover, .nav-links a.active {
  color: var(--white);
  background: rgba(255,255,255,.12);
}
.nav-user {
  color: rgba(255,255,255,.8);
  font-size: .85rem;
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-user .avatar {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--accent);
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: .85rem;
}

/* Mobile hamburger */
.hamburger { display: none; background:none; border:none; cursor:pointer; padding:8px; }
.hamburger span {
  display: block; width: 22px; height: 2px;
  background: #fff; margin: 5px 0;
  transition: .3s;
}

/* ── MAIN CONTENT ──────────────────────────── */
main {
  flex: 1;
  max-width: 1100px;
  width: 100%;
  margin: 0 auto;
  padding: 32px 24px;
}

.page-title {
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.page-subtitle {
  color: var(--grey-600);
  margin-bottom: 28px;
  font-size: .95rem;
}

/* ── CARDS ─────────────────────────────────── */
.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--grey-200);
  transition: box-shadow .2s, transform .2s;
}
.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}
.card-icon {
  font-size: 2rem;
  margin-bottom: 12px;
  display: block;
}
.card-label {
  font-size: .8rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--grey-600);
  font-weight: 600;
  margin-bottom: 6px;
}
.card-value {
  font-size: 1.15rem;
  font-weight: 600;
}
.card-detail {
  color: var(--grey-600);
  font-size: .88rem;
  margin-top: 4px;
}
.card-link {
  display: inline-block;
  margin-top: 14px;
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  font-size: .9rem;
}
.card-link:hover { text-decoration: underline; }

/* ── BADGES ────────────────────────────────── */
.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: .75rem;
  font-weight: 600;
}
.badge-green { background: var(--green-bg); color: var(--green); }
.badge-orange { background: var(--orange-bg); color: var(--orange); }
.badge-blue { background: #eff6ff; color: var(--accent); }

/* ── TABLE ─────────────────────────────────── */
.table-wrap {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--grey-200);
  overflow-x: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
}
th {
  background: var(--grey-50);
  text-align: left;
  padding: 14px 18px;
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .8px;
  color: var(--grey-600);
  font-weight: 700;
  border-bottom: 2px solid var(--grey-200);
}
td {
  padding: 16px 18px;
  border-bottom: 1px solid var(--grey-100);
  font-size: .9rem;
  vertical-align: top;
}
tr:last-child td { border-bottom: none; }
tr:hover { background: var(--grey-50); }

/* ── FORMS ─────────────────────────────────── */
.form-group { margin-bottom: 20px; }
.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
  font-size: .9rem;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid var(--grey-300);
  border-radius: var(--radius-sm);
  font-size: .95rem;
  font-family: inherit;
  transition: border-color .2s, box-shadow .2s;
  background: var(--white);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(58,134,255,.15);
}
.form-group textarea { resize: vertical; min-height: 100px; }

/* ── BUTTONS ───────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border: none;
  border-radius: var(--radius-sm);
  font-size: .95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
  font-family: inherit;
  text-decoration: none;
}
.btn-primary {
  background: var(--accent);
  color: var(--white);
}
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-secondary {
  background: var(--grey-100);
  color: var(--navy);
  border: 1.5px solid var(--grey-300);
}
.btn-secondary:hover { background: var(--grey-200); }
.btn-danger {
  background: var(--red);
  color: var(--white);
}
.btn-danger:hover { background: #dc2626; }

/* ── DOC LIST ──────────────────────────────── */
.doc-list { list-style: none; }
.doc-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--grey-100);
  transition: background .15s;
}
.doc-item:last-child { border-bottom: none; }
.doc-item:hover { background: var(--grey-50); }
.doc-info {
  display: flex;
  align-items: center;
  gap: 16px;
}
.doc-icon { font-size: 1.6rem; }
.doc-name { font-weight: 600; font-size: .95rem; }
.doc-meta { font-size: .8rem; color: var(--grey-600); }
.doc-download {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  font-size: .85rem;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--accent);
  transition: all .2s;
}
.doc-download:hover {
  background: var(--accent);
  color: var(--white);
}

/* ── EMERGENCY BANNER ──────────────────────── */
.emergency-banner {
  background: linear-gradient(135deg, var(--red), #dc2626);
  color: var(--white);
  padding: 24px 28px;
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 28px;
}
.emergency-banner .icon { font-size: 2.2rem; }
.emergency-banner .number {
  font-size: 1.8rem;
  font-weight: 800;
  letter-spacing: 1px;
}
.emergency-banner .label {
  font-size: .85rem;
  opacity: .9;
}

/* ── OFFICE CARDS ──────────────────────────── */
.office-card {
  display: flex;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--grey-100);
}
.office-card:last-child { border-bottom: none; }
.office-icon { font-size: 1.8rem; flex-shrink: 0; }
.office-name { font-weight: 700; font-size: 1rem; margin-bottom: 2px; }
.office-detail { font-size: .88rem; color: var(--grey-600); }

/* ── FOOTER ────────────────────────────────── */
footer {
  background: var(--navy-dark);
  color: rgba(255,255,255,.5);
  text-align: center;
  padding: 20px;
  font-size: .8rem;
}

/* ── ALERT / SUCCESS ───────────────────────── */
.alert {
  padding: 18px 24px;
  border-radius: var(--radius-sm);
  margin-bottom: 24px;
  font-weight: 500;
  display: none;
  align-items: center;
  gap: 12px;
}
.alert.show { display: flex; }
.alert-success { background: var(--green-bg); color: #065f46; border: 1px solid #a7f3d0; }
.alert-error { background: var(--red-bg); color: #991b1b; border: 1px solid #fecaca; }

/* ── LOGIN PAGE ────────────────────────────── */
.login-wrapper {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 50%, #1a365d 100%);
  min-height: 100vh;
}
.login-box {
  background: var(--white);
  border-radius: 16px;
  padding: 48px 40px;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 20px 60px rgba(0,0,0,.3);
}
.login-logo {
  text-align: center;
  margin-bottom: 8px;
}
.login-logo .brand {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 3px;
  color: var(--navy);
}
.login-logo .sub {
  font-size: .85rem;
  color: var(--grey-600);
  margin-top: 4px;
}
.login-divider {
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--navy));
  border: none;
  border-radius: 2px;
  margin: 24px 0;
}
.login-footer {
  text-align: center;
  margin-top: 28px;
  font-size: .78rem;
  color: var(--grey-600);
}

/* ── RESPONSIVE ────────────────────────────── */
@media (max-width: 768px) {
  .nav-links { 
    display: none;
    position: fixed;
    top: 64px; left: 0; right: 0;
    background: var(--navy);
    flex-direction: column;
    padding: 12px;
    gap: 2px;
    box-shadow: 0 4px 12px rgba(0,0,0,.3);
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 16px; }
  .hamburger { display: block; }
  .nav-user { display: none; }
  main { padding: 20px 16px; }
  .login-box { padding: 36px 28px; }
  .card { padding: 22px; }
  .emergency-banner { flex-direction: column; text-align: center; }
  .doc-item { flex-direction: column; align-items: flex-start; gap: 12px; }
  /* Responsive table */
  .table-wrap { border: none; box-shadow: none; background: transparent; }
  table, thead, tbody, th, td, tr { display: block; }
  thead { display: none; }
  tr {
    background: var(--white);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--grey-200);
    margin-bottom: 12px;
    padding: 16px;
  }
  td {
    padding: 6px 0;
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
  }
  td::before {
    content: attr(data-label);
    font-weight: 700;
    font-size: .78rem;
    text-transform: uppercase;
    color: var(--grey-600);
    letter-spacing: .5px;
    flex-shrink: 0;
    margin-right: 12px;
  }
}
