/* ===================================================
   UNIGREEN APPOINTMENTS - Maritime Theme
   =================================================== */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=DM+Sans:wght@300;400;500;600&display=swap');

:root {
  --navy:      #0a1628;
  --navy-mid:  #0e2247;
  --ocean:     #1a3a6b;
  --teal:      #0d7377;
  --teal-lt:   #14a085;
  --gold:      #c9a84c;
  --gold-lt:   #e8c56a;
  --white:     #f4f8ff;
  --fog:       #cdd8e8;
  --mist:      #8ba3c7;
  --danger:    #c0392b;
  --success:   #1a8a4a;

  --font-display: 'Playfair Display', Georgia, serif;
  --font-body:    'DM Sans', system-ui, sans-serif;

  --radius: 8px;
  --shadow: 0 4px 24px rgba(10,22,40,.25);
  --shadow-lg: 0 12px 48px rgba(10,22,40,.35);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--navy);
  color: var(--white);
  min-height: 100vh;
  line-height: 1.6;
}

/* ---- WAVE BACKGROUND ---- */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 0%, rgba(13,115,119,.18) 0%, transparent 60%),
    radial-gradient(ellipse 60% 80% at 80% 100%, rgba(26,58,107,.35) 0%, transparent 60%),
    linear-gradient(160deg, var(--navy) 0%, var(--navy-mid) 50%, var(--ocean) 100%);
  z-index: -1;
}

/* ---- TYPOGRAPHY ---- */
h1,h2,h3,h4 { font-family: var(--font-display); font-weight: 600; line-height: 1.2; }
h1 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
h3 { font-size: 1.25rem; }
p  { color: var(--fog); }

a { color: var(--teal-lt); text-decoration: none; transition: color .2s; }
a:hover { color: var(--gold-lt); }

/* ---- NAVBAR ---- */
.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
  background: rgba(10,22,40,.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(201,168,76,.2);
  position: sticky;
  top: 0;
  z-index: 100;
}
.navbar-brand {
  display: flex;
  align-items: center;
  gap: .75rem;
  text-decoration: none;
}
.navbar-brand img { height: 40px; filter: brightness(1.1); }
.navbar-brand span {
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: var(--gold-lt);
  letter-spacing: .03em;
}
.navbar-links { display: flex; align-items: center; gap: 1.5rem; }
.navbar-links a { color: var(--fog); font-size: .9rem; font-weight: 500; }
.navbar-links a:hover { color: var(--white); }
.navbar-links .btn-nav {
  background: linear-gradient(135deg, var(--teal), var(--teal-lt));
  color: var(--white) !important;
  padding: .45rem 1.1rem;
  border-radius: 50px;
  font-weight: 600;
}
.navbar-links .btn-nav:hover { opacity: .9; }

/* ---- HERO ---- */
.hero {
  position: relative;
  min-height: 78vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background: url('images/evergreen_carriers.png') center/cover no-repeat;
  opacity: .25;
  transform: scale(1.05);
  transition: transform 8s ease;
}
.hero:hover .hero-bg { transform: scale(1.0); }
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(10,22,40,.95) 40%, transparent 100%);
}
.hero-content {
  position: relative;
  z-index: 2;
  padding: 4rem 2rem 4rem 6%;
  max-width: 640px;
  animation: fadeUp .8s ease both;
}
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  background: rgba(201,168,76,.15);
  border: 1px solid rgba(201,168,76,.35);
  color: var(--gold-lt);
  padding: .3rem .9rem;
  border-radius: 50px;
  font-size: .8rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  margin-bottom: 1.2rem;
}
.hero-title { color: var(--white); margin-bottom: 1rem; }
.hero-title em { color: var(--gold-lt); font-style: normal; }
.hero-desc { font-size: 1.05rem; color: var(--fog); margin-bottom: 2rem; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .7rem 1.6rem;
  border-radius: 50px;
  font-family: var(--font-body);
  font-size: .95rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all .22s;
  text-decoration: none;
}
.btn-primary {
  background: linear-gradient(135deg, var(--teal) 0%, var(--teal-lt) 100%);
  color: var(--white);
  box-shadow: 0 4px 18px rgba(13,115,119,.4);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(13,115,119,.5); color: var(--white); }
.btn-outline {
  background: transparent;
  border: 1.5px solid var(--gold);
  color: var(--gold-lt);
}
.btn-outline:hover { background: rgba(201,168,76,.1); transform: translateY(-2px); color: var(--gold-lt); }
.btn-danger {
  background: var(--danger);
  color: #fff;
}
.btn-danger:hover { opacity: .85; }
.btn-sm { padding: .4rem 1rem; font-size: .85rem; }
.btn-block { width: 100%; justify-content: center; border-radius: var(--radius); }

/* ---- CARDS ---- */
.card {
  background: rgba(14,34,71,.7);
  border: 1px solid rgba(139,163,199,.15);
  border-radius: 16px;
  padding: 1.8rem;
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  transition: transform .25s, box-shadow .25s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card-icon {
  width: 52px; height: 52px;
  background: linear-gradient(135deg, var(--teal), var(--ocean));
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

/* ---- FEATURES SECTION ---- */
.section { padding: 5rem 6% 4rem; }
.section-title { text-align: center; margin-bottom: .5rem; }
.section-sub { text-align: center; color: var(--mist); margin-bottom: 3rem; font-size: 1.05rem; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.5rem; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 1.5rem; }

/* ---- FORMS ---- */
.form-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}
.form-box {
  background: rgba(14,34,71,.85);
  border: 1px solid rgba(139,163,199,.2);
  border-radius: 20px;
  padding: 2.5rem 2.2rem;
  width: 100%;
  max-width: 440px;
  backdrop-filter: blur(16px);
  box-shadow: var(--shadow-lg);
  animation: fadeUp .6s ease both;
}
.form-logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .5rem;
  margin-bottom: 1.8rem;
}
.form-logo img { height: 52px; }
.form-logo h2 { margin: 0; font-size: 1.4rem; color: var(--white); }
.form-logo p { color: var(--mist); font-size: .85rem; margin: 0; }

.form-group { margin-bottom: 1.1rem; }
.form-group label {
  display: block;
  font-size: .83rem;
  font-weight: 600;
  color: var(--mist);
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: .4rem;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  background: rgba(10,22,40,.6);
  border: 1px solid rgba(139,163,199,.25);
  border-radius: var(--radius);
  color: var(--white);
  padding: .65rem .9rem;
  font-family: var(--font-body);
  font-size: .95rem;
  transition: border-color .2s, box-shadow .2s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--teal-lt);
  box-shadow: 0 0 0 3px rgba(20,160,133,.18);
}
.form-group input::placeholder { color: var(--mist); opacity: .6; }
.form-group select option { background: var(--navy-mid); }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

.form-divider {
  text-align: center;
  color: var(--mist);
  font-size: .88rem;
  margin: 1rem 0;
  position: relative;
}
.form-divider::before, .form-divider::after {
  content: '';
  position: absolute;
  top: 50%; width: 40%;
  height: 1px;
  background: rgba(139,163,199,.2);
}
.form-divider::before { left: 0; }
.form-divider::after { right: 0; }

.alert {
  padding: .75rem 1rem;
  border-radius: var(--radius);
  font-size: .9rem;
  margin-bottom: 1rem;
}
.alert-error { background: rgba(192,57,43,.15); border: 1px solid rgba(192,57,43,.4); color: #f1948a; }
.alert-success { background: rgba(26,138,74,.15); border: 1px solid rgba(26,138,74,.4); color: #82e0aa; }
.alert-info { background: rgba(13,115,119,.15); border: 1px solid rgba(13,115,119,.4); color: var(--teal-lt); }

/* ---- DASHBOARD ---- */
.dashboard-layout {
  display: flex;
  min-height: 100vh;
}
.sidebar {
  width: 240px;
  flex-shrink: 0;
  background: rgba(10,22,40,.95);
  border-right: 1px solid rgba(139,163,199,.1);
  padding: 1.5rem 0;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}
.sidebar-logo {
  padding: 0 1.2rem 1.5rem;
  border-bottom: 1px solid rgba(139,163,199,.1);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: .6rem;
}
.sidebar-logo img { height: 32px; }
.sidebar-logo span { font-family: var(--font-display); font-size: .95rem; color: var(--gold-lt); }
.sidebar-section {
  padding: .3rem 1.2rem .1rem;
  font-size: .7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--mist);
  margin-top: .8rem;
}
.sidebar-link {
  display: flex;
  align-items: center;
  gap: .65rem;
  padding: .65rem 1.2rem;
  color: var(--fog);
  font-size: .92rem;
  text-decoration: none;
  transition: all .15s;
  border-left: 3px solid transparent;
}
.sidebar-link:hover { background: rgba(139,163,199,.08); color: var(--white); }
.sidebar-link.active {
  background: rgba(13,115,119,.15);
  border-left-color: var(--teal-lt);
  color: var(--teal-lt);
}
.sidebar-link .icon { font-size: 1.05rem; width: 20px; text-align: center; }

.main-content { flex: 1; padding: 2rem; overflow-x: hidden; }
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1rem;
}
.page-header h1 { font-size: 1.6rem; }

/* ---- STATS CARDS ---- */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 1.2rem; margin-bottom: 2rem; }
.stat-card {
  background: rgba(14,34,71,.7);
  border: 1px solid rgba(139,163,199,.12);
  border-radius: 12px;
  padding: 1.3rem 1.5rem;
}
.stat-card .label { font-size: .8rem; color: var(--mist); text-transform: uppercase; letter-spacing: .06em; }
.stat-card .value { font-size: 2rem; font-family: var(--font-display); color: var(--white); margin: .2rem 0; }
.stat-card .change { font-size: .83rem; color: var(--teal-lt); }

/* ---- TABLE ---- */
.table-wrap {
  background: rgba(14,34,71,.6);
  border: 1px solid rgba(139,163,199,.12);
  border-radius: 14px;
  overflow: hidden;
}
table { width: 100%; border-collapse: collapse; }
thead { background: rgba(10,22,40,.7); }
thead th {
  padding: .85rem 1.2rem;
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--mist);
  text-align: left;
}
tbody tr { border-bottom: 1px solid rgba(139,163,199,.07); transition: background .15s; }
tbody tr:last-child { border-bottom: none; }
tbody tr:hover { background: rgba(139,163,199,.05); }
tbody td { padding: .85rem 1.2rem; font-size: .92rem; color: var(--fog); }
tbody td strong { color: var(--white); }

/* ---- BADGES ---- */
.badge {
  display: inline-flex;
  align-items: center;
  padding: .22rem .7rem;
  border-radius: 50px;
  font-size: .75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.badge-pending  { background: rgba(201,168,76,.15); color: var(--gold-lt); border: 1px solid rgba(201,168,76,.3); }
.badge-confirmed{ background: rgba(26,138,74,.15);  color: #82e0aa; border: 1px solid rgba(26,138,74,.3); }
.badge-cancelled{ background: rgba(192,57,43,.15);  color: #f1948a; border: 1px solid rgba(192,57,43,.3); }
.badge-completed{ background: rgba(13,115,119,.15); color: var(--teal-lt); border: 1px solid rgba(13,115,119,.3); }

/* ---- MODAL ---- */
.modal-backdrop {
  display: none;
  position: fixed; inset: 0;
  background: rgba(5,12,24,.75);
  z-index: 200;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}
.modal-backdrop.open { display: flex; }
.modal {
  background: var(--navy-mid);
  border: 1px solid rgba(139,163,199,.2);
  border-radius: 18px;
  padding: 2rem;
  width: 100%;
  max-width: 500px;
  box-shadow: var(--shadow-lg);
  animation: fadeUp .3s ease both;
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}
.modal-close { background: none; border: none; color: var(--mist); font-size: 1.3rem; cursor: pointer; }
.modal-close:hover { color: var(--white); }

/* ---- CLIENT PORTAL ---- */
.portal-header {
  background: rgba(10,22,40,.9);
  border-bottom: 1px solid rgba(201,168,76,.15);
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.portal-header .brand {
  display: flex; align-items: center; gap: .6rem;
  font-family: var(--font-display); color: var(--gold-lt); font-size: 1rem;
}
.portal-header .brand img { height: 36px; }
.portal-header .user-info { display: flex; align-items: center; gap: 1rem; color: var(--fog); font-size: .9rem; }

/* ---- APPOINTMENT BOOKING ---- */
.booking-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 2rem;
  align-items: start;
}
@media (max-width: 768px) {
  .booking-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .hero-content { padding: 3rem 1.5rem; }
  .sidebar { display: none; }
  .dashboard-layout { display: block; }
  .main-content { padding: 1.2rem; }
  .navbar { padding: .8rem 1rem; }
}

/* ---- CALENDAR PICKER ---- */
.time-slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: .5rem;
  margin-top: .5rem;
}
.time-slot {
  padding: .45rem;
  border: 1px solid rgba(139,163,199,.2);
  border-radius: 6px;
  text-align: center;
  font-size: .83rem;
  cursor: pointer;
  color: var(--fog);
  background: rgba(10,22,40,.4);
  transition: all .15s;
}
.time-slot:hover, .time-slot.selected {
  background: rgba(13,115,119,.2);
  border-color: var(--teal-lt);
  color: var(--teal-lt);
}
.time-slot.booked { opacity: .35; cursor: not-allowed; }

/* ---- EMPTY STATE ---- */
.empty-state {
  text-align: center;
  padding: 3rem 2rem;
  color: var(--mist);
}
.empty-state .icon { font-size: 3rem; margin-bottom: 1rem; opacity: .4; }
.empty-state p { font-size: 1rem; }

/* ---- DIVIDER LINE ---- */
.divider { border: none; border-top: 1px solid rgba(139,163,199,.12); margin: 1.5rem 0; }

/* ---- FOOTER ---- */
footer {
  background: rgba(5,12,24,.8);
  border-top: 1px solid rgba(139,163,199,.1);
  padding: 2rem 6%;
  text-align: center;
  color: var(--mist);
  font-size: .85rem;
}
footer span { color: var(--gold); }

/* ---- ANIMATIONS ---- */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
.fade-in { animation: fadeIn .5s ease both; }

/* ---- UTILITIES ---- */
.text-gold { color: var(--gold-lt); }
.text-teal { color: var(--teal-lt); }
.text-muted { color: var(--mist); }
.text-center { text-align: center; }
.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: .5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.d-flex { display: flex; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: .5rem; }
.gap-2 { gap: 1rem; }
.flex-1 { flex: 1; }
