﻿@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&display=swap');

/* =========================================================
   1. COLOR PALETTE & GLOBAL RESET (NEW THEME)
   ========================================================= */
:root { 
  --brand-pink: #ffcbfe;
  --brand-blue: #8bb4d7;
  --brand-navy: #1c2b67;
  --brand-light: #faf9fc;
  --brand-muted: #4b5563;
  --brand-line: rgba(28, 43, 103, 0.15);
  
  /* Status Color Variables - High Contrast & Solid Colors */
  --status-green-bg: #dcfce7;
  --status-green-text: #14532d;
  --status-green-border: #86efac;

  --status-red-bg: #fee2e2;
  --status-red-text: #7f1d1d;
  --status-red-border: #fca5a5;

  --status-yellow-bg: #fef3c7;
  --status-yellow-text: #78350f;
  --status-yellow-border: #fde047;

  --status-blue-bg: #e0f2fe;
  --status-blue-text: #0c4a6e;
  --status-blue-border: #7dd3fc;

  /* Aliasing untuk kompatibilitas */
  --ink: var(--brand-navy); 
  --muted: var(--brand-muted); 
  --paper: #f3f0f7;
  --cream: var(--brand-light);
  --accent: var(--brand-blue); 
  --line: var(--brand-line); 
}

* { 
  box-sizing: border-box; 
}

html { 
  scroll-behavior: smooth; 
}

body { 
  margin: 0; 
  background: var(--paper); 
  color: var(--brand-navy); 
  font: 16px/1.7 'Inter', sans-serif; 
}

/* =========================================================
   2. PUBLIC INVITATION CANVAS (MOBILE-FIRST VIEW ON DESKTOP)
   ========================================================= */
.invitation { 
  max-width: 480px; 
  margin: 0 auto; 
  background: var(--brand-light); 
  box-shadow: 0 10px 40px rgba(28, 43, 103, 0.08); 
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* Hero Section */
.hero { 
  min-height: 100vh; 
  padding: 10vh 6vw 6vh; 
  display: flex; 
  flex-direction: column; 
  justify-content: center; 
  align-items: center; 
  text-align: center; 
  background: linear-gradient(135deg, rgba(255, 203, 254, 0.3) 0%, rgba(139, 180, 215, 0.3) 50%, rgba(28, 43, 103, 0.1) 100%); 
}

.eyebrow { 
  margin: 0 0 12px; 
  color: var(--brand-navy); 
  background: var(--brand-pink);
  padding: 4px 12px;
  border-radius: 9999px;
  font-size: 11px; 
  letter-spacing: .15em; 
  text-transform: uppercase; 
  font-weight: 700; 
  display: inline-block;
}

h1, h2, h3 { 
  font-family: 'Playfair Display', Georgia, serif; 
  font-weight: 600; 
  line-height: 1.2; 
  color: var(--brand-navy);
}

h1 { 
  max-width: 100%; 
  margin: 12px 0; 
  font-size: clamp(2.5rem, 8vw, 3.8rem); 
}

h2 { 
  margin: 0 0 20px; 
  font-size: clamp(2rem, 6vw, 2.8rem); 
}

h2 span { 
  color: var(--brand-blue); 
}

h3 { 
  margin: 8px 0; 
  font-size: 1.8rem; 
}

.hero-date { 
  letter-spacing: .2em; 
  text-transform: uppercase; 
  color: var(--brand-muted); 
  font-size: 0.9rem;
}

.guest-note { 
  margin: 40px 0 24px; 
  color: var(--brand-muted); 
}

.guest-note strong { 
  color: var(--brand-navy); 
  font-size: 1.1rem; 
}

/* Common UI Components */
.button { 
  display: inline-flex; 
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0; 
  background: var(--brand-navy); 
  color: white; 
  padding: 12px 28px; 
  border-radius: 9999px;
  text-decoration: none; 
  font: 600 13px 'Inter', sans-serif; 
  letter-spacing: .05em; 
  cursor: pointer; 
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(28, 43, 103, 0.15);
}

.button-sm {
  padding: 8px 16px;
  font-size: 12px;
}

.button-secondary {
  background: var(--brand-blue);
  color: var(--brand-navy);
}

.button-secondary:hover {
  background: var(--brand-navy);
  color: #ffffff;
}

.button-danger { 
  background: #e53e3e; 
  color: white;
}

.button-danger:hover {
  background: #c53030;
  color: white;
}

.button:hover { 
  background: var(--brand-blue); 
  color: var(--brand-navy);
  transform: translateY(-2px);
}

.section { 
  padding: 60px 6%; 
  text-align: center; 
}

.intro { 
  background: var(--brand-light); 
}

.intro > p:not(.eyebrow) { 
  max-width: 100%; 
  margin: 0 auto 28px; 
  color: var(--brand-muted); 
}

.event-card { 
  max-width: 100%; 
  margin: 28px auto 0; 
  padding: 28px 20px; 
  border: 1px solid var(--brand-line); 
  background: #ffffff; 
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

.event-card p { 
  margin: 4px 0; 
  color: var(--brand-muted); 
}

.text-link { 
  display: inline-block; 
  margin-top: 18px; 
  color: var(--brand-navy); 
  font-weight: 600; 
  text-decoration: none;
}

.text-link:hover {
  color: var(--brand-blue);
}

/* Gallery & Bank Section */
.gallery-section, .gift-section { 
  background: rgba(238, 242, 246, 0.6); 
}

.gallery { 
  display: grid; 
  grid-template-columns: repeat(2, 1fr); 
  gap: 12px; 
  max-width: 100%; 
  margin: 24px auto 0; 
}

.gallery img { 
  width: 100%; 
  aspect-ratio: 1; 
  object-fit: cover; 
  border-radius: 12px;
}

.bank-list { 
  display: grid; 
  gap: 12px; 
  max-width: 100%; 
  margin: 24px auto 0; 
}

.bank-card { 
  display: grid; 
  gap: 4px; 
  padding: 20px; 
  border: 1px solid var(--brand-line); 
  border-radius: 16px;
  text-align: left; 
  background: #ffffff; 
}

.bank-card strong { 
  color: var(--brand-navy); 
}

.bank-card span { 
  font-size: 1.15rem; 
  letter-spacing: .04em; 
  color: var(--brand-navy);
  font-weight: 600;
}

.bank-card small { 
  color: var(--brand-muted); 
}

/* RSVP & Wishes Form Section */
.response-section { 
  background: rgba(255, 203, 254, 0.15); 
}

form { 
  max-width: 100%; 
  margin: 24px auto 0; 
  text-align: left; 
}

.response-section form { 
  display: grid; 
  grid-template-columns: 1fr; 
  gap: 12px; 
}

.response-section form .button { 
  justify-self: start; 
}

label { 
  display: grid; 
  gap: 6px; 
  margin-bottom: 14px; 
  color: var(--brand-navy); 
  font-size: 13px; 
  font-weight: 600; 
} 

.form-help {
  font-size: 12px;
  color: var(--brand-muted);
  font-weight: normal;
  margin-top: -2px;
}

input, select, textarea { 
  width: 100%; 
  padding: 12px 16px; 
  border: 1px solid var(--brand-line); 
  border-radius: 12px;
  background: #ffffff; 
  color: var(--brand-navy); 
  font: inherit; 
  outline: none;
  transition: border-color 0.2s;
} 

input:focus, select:focus, textarea:focus {
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 3px rgba(139, 180, 215, 0.25);
}

textarea { 
  resize: vertical; 
}

blockquote { 
  max-width: 100%; 
  margin: 16px auto; 
  padding: 16px 20px; 
  border-left: 4px solid var(--brand-blue); 
  border-radius: 0 12px 12px 0;
  background: #ffffff; 
  text-align: left; 
} 

blockquote p { 
  margin: 0 0 5px; 
  color: var(--brand-muted);
} 

cite { 
  color: var(--brand-navy); 
  font-size: 13px; 
  font-style: normal; 
  font-weight: 600; 
}

footer { 
  padding: 50px 6%; 
  text-align: center; 
  background: var(--brand-navy); 
  color: var(--brand-light); 
} 

footer p { 
  color: rgba(250, 249, 252, 0.7); 
}

@media (max-width: 520px) { 
  .invitation {
    max-width: 100%;
    box-shadow: none;
  }
  .hero { 
    min-height: 100vh; 
  } 
  .section { 
    padding: 50px 5%; 
  } 
  .gallery { 
    gap: 8px; 
  } 
}

/* =========================================================
   3. ADMIN BURGER MENU & NAVIGATION DRAWER (STRUCTURE ORIGINAL)
   ========================================================= */
.admin-burger { 
  position: fixed; 
  left: 0; 
  top: 0; 
  z-index: 50; 
} 

.admin-burger details { 
  height: auto; 
} 

.admin-burger summary { 
  position: relative; 
  z-index: 2; 
  width: 52px; 
  height: 52px; 
  display: grid; 
  place-content: center; 
  border: 1px solid var(--brand-line); 
  background: var(--brand-light); 
  cursor: pointer; 
  list-style: none; 
  transition: all 0.2s ease; 
} 

.admin-burger summary:hover { 
  background: var(--brand-pink); 
} 

.admin-burger summary::-webkit-details-marker { 
  display: none; 
} 

.admin-burger summary::before { 
  content: "\f0c9"; 
  font-family: "Font Awesome 6 Free"; 
  font-weight: 900; 
  font-size: 20px; 
  color: var(--brand-navy); 
} 

.admin-burger details[open] summary::before { 
  content: "\f00d"; 
} 

.admin-burger details[open] summary::after { 
  content: ''; 
  position: fixed; 
  inset: 0; 
  background: rgba(28, 43, 103, 0.4); 
  z-index: -1; 
  cursor: default; 
} 

.admin-burger-panel { 
  position: fixed; 
  left: 0; 
  top: 52px; 
  bottom: 0; 
  width: 280px; 
  padding: 18px 12px; 
  border: 1px solid var(--brand-line); 
  border-left: 0; 
  border-bottom: 0; 
  background: var(--brand-light); 
  box-shadow: 12px 0 30px rgba(28, 43, 103, 0.15); 
  overflow-y: auto; 
  z-index: 3; 
}

.admin-burger-panel a { 
  display: block; 
  padding: 10px 14px; 
  color: var(--brand-navy); 
  text-decoration: none; 
  font-weight: 600; 
  border-radius: 8px;
  transition: all 0.2s ease;
}

.admin-burger-panel a:hover, .admin-burger-panel a.active { 
  background: rgba(255, 203, 254, 0.6); 
  color: var(--brand-navy); 
}

.session-identity { 
  padding: 8px 12px; 
  color: var(--brand-muted); 
  font-size: 12px; 
  border-bottom: 1px solid var(--brand-line);
  margin-bottom: 12px;
}

/* =========================================================
   4. ADMIN & BACK-OFFICE DASHBOARD 
   ========================================================= */
.auth-page { 
  min-height: 100vh; 
  width: 100%; 
  display: grid; 
  place-items: center; 
  padding: 40px 20px;
}

.dashboard { 
  min-height: 100vh; 
  width: 100%; 
  max-width: 1800px; 
  margin: 0 auto; 
  padding: 40px 3%; 
}

.auth-card { 
  width: min(100%, 440px); 
  padding: 36px; 
  background: #ffffff; 
  border: 1px solid var(--brand-line); 
  border-radius: 24px;
  box-shadow: 0 10px 30px rgba(28, 43, 103, 0.05);
}

.auth-card h1 { 
  font-size: 2.2rem; 
}

.auth-card form { 
  margin-top: 24px; 
}

.form-error { 
  padding: 10px 14px; 
  background: var(--status-red-bg); 
  color: var(--status-red-text); 
  border: 1px solid var(--status-red-border);
  border-radius: 8px;
  font-size: 14px;
}

.form-success { 
  padding: 10px 14px; 
  background: var(--status-green-bg); 
  color: var(--status-green-text); 
  border: 1px solid var(--status-green-border);
  border-radius: 8px;
  font-size: 14px;
}

.dashboard-head { 
  display: flex; 
  align-items: center; 
  justify-content: space-between; 
  border-bottom: 1px solid var(--brand-line); 
  padding-bottom: 20px;
}

.dashboard-head h1 { 
  margin: 0; 
  font-size: 2.2rem; 
  display: flex; 
  align-items: center; 
  gap: 16px; 
}

.back-btn { 
  display: inline-flex; 
  align-items: center; 
  justify-content: center; 
  width: 44px; 
  height: 44px; 
  border-radius: 50%; 
  background: #ffffff; 
  border: 1px solid var(--brand-line); 
  color: var(--brand-muted); 
  text-decoration: none; 
  font-size: 1.25rem; 
  transition: all 0.2s; 
  flex-shrink: 0; 
}

.back-btn:hover { 
  background: var(--brand-blue); 
  color: var(--brand-navy); 
  transform: translateX(-3px); 
}

.dashboard-welcome { 
  color: var(--brand-muted); 
  margin: 20px 0 30px; 
}

.dashboard-grid { 
  display: grid; 
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
  gap: 20px; 
}

.dashboard-card, .empty-state { 
  padding: 28px; 
  border: 1px solid var(--brand-line); 
  background: #ffffff; 
  border-radius: 20px;
  box-shadow: 0 4px 15px rgba(28, 43, 103, 0.03);
}

.dashboard-card h2, .empty-state h2 { 
  font-size: 1.8rem; 
}

/* =========================================================
   5. COMPLETE STATUS BADGES & INDICATORS (WARNA MUNCUL JELAS)
   ========================================================= */
.badge, .status-badge, .pill-tag, .status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 700;
  text-transform: capitalize;
  line-height: 1.4;
  white-space: nowrap;
}

/* Status: Success / Hadir / Approved / Active */
.badge-success, 
.status-badge.success, 
.status-badge.attending, 
.status-badge.hadir,
.pill-tag.attending, 
.pill-tag.hadir,
.status.active,
.status.confirmed,
.status-active {
  background-color: var(--status-green-bg) !important;
  color: var(--status-green-text) !important;
  border: 1px solid var(--status-green-border) !important;
}

/* Status: Danger / Tidak Hadir / Rejected / Inactive / Expired / Suspended */
.badge-danger, 
.status-badge.danger, 
.status-badge.declined, 
.status-badge.absent,
.status-badge.tidak-hadir,
.pill-tag.declined, 
.pill-tag.tidak-hadir,
.status.inactive,
.status.rejected,
.status-expired, 
.status-inactive, 
.status-suspended {
  background-color: var(--status-red-bg) !important;
  color: var(--status-red-text) !important;
  border: 1px solid var(--status-red-border) !important;
}

/* Status: Warning / Pending / Ragu-ragu */
.badge-warning, 
.status-badge.warning, 
.status-badge.pending, 
.status-badge.maybe,
.pill-tag.pending, 
.pill-tag.maybe,
.status.pending,
.status-pending {
  background-color: var(--status-yellow-bg) !important;
  color: var(--status-yellow-text) !important;
  border: 1px solid var(--status-yellow-border) !important;
}

/* Status: Info / Draft / General */
.badge-info, 
.status-badge.info, 
.status-badge.draft,
.pill-tag.info,
.status.info {
  background-color: var(--status-blue-bg) !important;
  color: var(--status-blue-text) !important;
  border: 1px solid var(--status-blue-border) !important;
}

/* Status Dot Indicator */
.status-indicator, .status-dot { 
  display: inline-block; 
  width: 10px; 
  height: 10px; 
  border-radius: 50%; 
  vertical-align: middle; 
}

.status-indicator.status-active, .status-dot.success { background-color: #16a34a !important; }
.status-indicator.status-expired, .status-indicator.status-inactive, .status-indicator.status-suspended, .status-dot.danger { background-color: #dc2626 !important; }
.status-indicator.status-pending, .status-dot.warning { background-color: #d97706 !important; }

/* =========================================================
   6. STATS & TABLES
   ========================================================= */
.stat-grid { 
  display: grid; 
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); 
  gap: 16px; 
  margin: 24px 0; 
}

.stat-card { 
  display: grid; 
  gap: 4px; 
  padding: 20px; 
  border: 1px solid var(--brand-line); 
  border-radius: 16px;
  background: rgba(139, 180, 215, 0.15); 
}

.stat-card strong { 
  font: 2.2rem 'Playfair Display', Georgia, serif; 
  color: var(--brand-navy);
}

.stat-card span, .dashboard-card small { 
  color: var(--brand-muted); 
}

.action-row { 
  display: flex; 
  flex-wrap: wrap; 
  gap: 14px; 
  margin-top: 18px; 
}

.admin-form { 
  max-width: 100%; 
  margin: 24px 0; 
}

.admin-form input::placeholder, .admin-form textarea::placeholder { 
  color: var(--brand-muted); 
  opacity: .5; 
}

.admin-form label { 
  color: var(--brand-navy); 
}

.admin-form label > small, .admin-form > .field-help { 
  display: block; 
  margin-top: 4px; 
  color: var(--brand-muted); 
  font-size: .75rem; 
  font-weight: 400; 
  line-height: 1.4; 
}

.form-grid { 
  display: grid; 
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); 
  gap: 0 24px; 
}

.inline-form, .search-form { 
  display: flex; 
  flex-wrap: wrap; 
  gap: 12px; 
  align-items: end; 
  max-width: none; 
}

.inline-form label { 
  flex: 1; 
}

.inline-form input, .search-form input { 
  flex: 1; 
  min-width: 200px; 
}

.danger-button { 
  border: 0; 
  background: var(--status-red-bg); 
  color: var(--status-red-text); 
  padding: 10px 16px; 
  border-radius: 9999px;
  cursor: pointer; 
  font-weight: 600;
  transition: background 0.2s;
}

.danger-button:hover {
  background: #fca5a5;
}

/* Tables Styling */
.table-wrap, .wishes-table { 
  width: 100%;
  overflow-x: auto; 
  margin-top: 24px; 
  border: 1px solid var(--brand-line);
  border-radius: 16px;
}

table { 
  width: 100%; 
  border-collapse: collapse; 
  background: #ffffff; 
}

th, td { 
  padding: 14px 16px; 
  border-bottom: 1px solid var(--brand-line); 
  text-align: left; 
  white-space: normal; 
  word-break: break-word;
}

th { 
  color: var(--brand-navy); 
  background: rgba(250, 249, 252, 0.8);
  font-size: 12px; 
  font-weight: 700;
  text-transform: uppercase; 
  letter-spacing: 0.05em;
  white-space: nowrap; 
}

.data-table-card { 
  padding: 24px; 
}

.table-toolbar { 
  display: flex; 
  align-items: center; 
  justify-content: space-between;
  gap: 16px; 
  margin-bottom: 16px; 
}

.table-toolbar label { 
  margin: 0; 
  white-space: nowrap; 
}

.table-toolbar input { 
  max-width: 480px; 
}

.sortable-header { 
  cursor: pointer; 
  user-select: none; 
}

.sortable-header:hover, .sortable-header:focus { 
  color: var(--brand-blue); 
  outline: none; 
}

.data-table-wrap table { 
  min-width: 100%; 
}

.sticky-action th:last-child, .sticky-action td:last-child,
.wishes-table .action-cell { 
  position: sticky; 
  right: 0; 
  background: #ffffff; 
  z-index: 10; 
  box-shadow: -4px 0 10px rgba(0,0,0,0.03); 
  border-left: 1px solid var(--brand-line); 
  white-space: nowrap;
}

.action-buttons { 
  display: flex; 
  gap: 8px; 
  align-items: center; 
}

.action-buttons form { 
  margin: 0; 
  display: flex; 
  align-items: center; 
}

.action-buttons .text-link, .wishes-table .action-buttons .text-link { 
  margin-top: 0; 
  padding: 0; 
  display: inline-flex; 
  align-items: center; 
  justify-content: center; 
  width: 34px; 
  height: 34px; 
  background: rgba(139, 180, 215, 0.2); 
  border-radius: 8px; 
  color: var(--brand-navy);
  transition: all 0.2s ease;
}

.action-buttons .text-link:hover {
  background: var(--brand-blue);
  color: var(--brand-navy);
}

.action-buttons .danger-button { 
  padding: 0; 
  display: inline-flex; 
  align-items: center; 
  justify-content: center; 
  width: 34px; 
  height: 34px; 
  border-radius: 8px; 
}

/* Saved Wedding Data & Grid */
.saved-wedding-data { 
  margin: 24px 0 0; 
}

.saved-data-grid { 
  display: grid; 
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); 
  gap: 16px; 
}

.saved-data-grid div { 
  padding: 14px; 
  border-left: 3px solid var(--brand-blue); 
  border-radius: 0 12px 12px 0;
  background: var(--brand-light); 
}

.saved-data-grid span { 
  display: block; 
  color: var(--brand-muted); 
  font-size: 12px; 
}

.saved-data-grid strong { 
  display: block; 
  font-weight: 600; 
  white-space: pre-wrap; 
}

/* Media Grid & Cards */
.media-grid, .wish-admin-list { 
  display: grid; 
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); 
  gap: 20px; 
  margin-top: 24px; 
}

.media-preview { 
  width: 100%; 
  aspect-ratio: 1.2; 
  object-fit: cover; 
  border-radius: 12px;
  margin-bottom: 12px; 
}

.media-icon { 
  color: var(--brand-navy); 
  font-weight: 700; 
}

.qris-image { 
  display: block; 
  width: min(280px, 100%); 
  margin: 24px auto 0; 
  border-radius: 12px;
}

.wish-admin-list small { 
  display: block; 
  margin-top: 8px; 
  color: var(--brand-muted); 
}

@media (max-width: 768px) { 
  .dashboard {
    padding: 24px 4%;
  }
  .stat-grid { 
    grid-template-columns: repeat(2, 1fr); 
  } 
  .form-grid { 
    grid-template-columns: 1fr; 
  } 
  .dashboard-head { 
    align-items: start; 
    gap: 12px; 
    flex-direction: column; 
  } 
  .table-toolbar { 
    flex-direction: column;
    align-items: stretch;
  } 
  .table-toolbar input { 
    max-width: none; 
  } 
  .data-table-card { 
    padding: 12px; 
  } 
  .data-table-wrap th, .data-table-wrap td { 
    padding: 9px 8px; 
    font-size: 12px; 
  } 
}

/* Styling Tombol Floating & Vinyl Media Player */
.floating-controls-stack {
    position: fixed;
    bottom: 25px;
    right: 20px;
    z-index: 999;
}

.music-control-btn.vinyl-player {
    width: 50px;
    height: 50px;
    background: transparent;
    border: none;
    padding: 0;
    cursor: pointer;
    outline: none;
    box-shadow: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.vinyl-disc {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 50%;
    /* Efek bayangan tipis & transisi mulus saat berhenti */
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
    transition: transform 0.3s ease;
}

/* Animasi Putar Vinyl */
.spin-animation {
    animation: rotateVinyl 4s linear infinite;
}

/* Class saat lagu dipause (animasi berhenti) */
.spin-animation.paused {
    animation-play-state: paused;
}

@keyframes rotateVinyl {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}