/*
 * File: rsvp-styles.css
 * Theme: Soft Warm Dashboard (Manrope + Yellow Accent)
 */

/* --------- THEME TOKENS --------- */
:root {
  --font-ui: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", Arial, sans-serif;

  /* Text */
  --text-900: #1f2430;   /* judul / teks utama */
  --text-700: #2b313f;   /* isi tabel */
  --text-500: #818898;   /* subtitel */
  --muted-400: #aab1be;  /* hint */

  /* Surfaces & borders */
  --panel: #ffffff;
  --panel-weak: #f7f8fb;
  --panel-strong: #f3f4f7;
  --border: #e8eaef;

  /* Accent (kuning lembut seperti referensi) */
  --accent: #f4c84a;
  --accent-700: #e7b935;
  --accent--800: #0065a8;

  /* Table states */
  --thead: #fafbfc;
  --row-hover: #f7f7fb;

  /* Container subtle gradient ala referensi */
  --panel-gradient: radial-gradient(1200px 600px at 100% 0%, #fff6d8 0%, #ffffff 35%),
                    linear-gradient(180deg, #ffffff 0%, #f7f8fb 100%);
  --panel-gradient-blue: radial-gradient(1200px 600px at 100% 0%, #c1e8ff 0%, #ffffff 35%), linear-gradient(180deg, #ffffff 0%, #f7f8fb 100%);
}

/* --- GENERAL RESET & BASE STYLES --- */
.rsvp-container * { box-sizing: border-box; margin: 0; padding: 0; }

body {
    padding: 25px;
    background: var(--panel-gradient-blue);
  	height: 100vh;
}

.rsvp-container {
  font-family: var(--font-ui);
  color: var(--text-700);
  max-width: 1200px;
  margin: 40px auto;
  padding: 0 15px;
  line-height: 1.6;
  background: #00000000;
  border-radius: 14px;
}

/* --- TITLE & HEADING --- */
.rsvp-container h1 {
  text-align: center;
  font-size: 1.8em;
  font-weight: 600;
  margin-bottom: 30px;
  color: var(--text-900);
  letter-spacing: -0.2px;
  position: relative;
  padding-bottom: 40px;
  padding-top: 40px;
}

.rsvp-container h1::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 64px;
  height: 3px;
  background-color: var(--accent);
  border-radius: 3px;
}

/* --- INFO BAR --- */
.rsvp-info-bar {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--border);
  gap: 12px;
}

.rsvp-info-bar p {
  font-size: 0.95em;
  font-weight: 500;
  color: var(--text-500);
}

.rsvp-info-bar span {
  color: var(--accent-700);
  font-weight: 700;
}

.rsvp-export-button {
  padding: 12px 20px;
  background-color: transparent;
  color: var(--text-900);
  text-decoration: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  transition: all 0.25s ease;
  font-weight: 600;
  width: 100%;
  text-align: center;
  letter-spacing: 0.2px;
  font-size: 0.92em;
}

.rsvp-export-button:hover {
  border-color: var(--accent);
  box-shadow: 0 4px 18px rgba(244, 200, 74, 0.18);
}

/* --- TABLE STYLES - MOBILE FIRST --- */
.rsvp-table-wrapper {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(19, 22, 30, 0.04);
  margin-bottom: 30px;
  background:
    linear-gradient(to right, white 30%, rgba(255,255,255,0)),
    linear-gradient(to left, white 30%, rgba(255,255,255,0)) 100% 0,
    radial-gradient(farthest-side at 0% 50%, rgba(0,0,0,.08), transparent),
    radial-gradient(farthest-side at 100% 50%, rgba(0,0,0,.08), transparent) 100% 0;
  background-repeat: no-repeat;
  background-color: var(--panel);
  background-size: 40px 100%, 40px 100%, 14px 100%, 14px 100%;
  background-attachment: local, local, scroll, scroll;
}

.rsvp-table {
  width: 100%;
  min-width: 600px;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9em;
}

.rsvp-table thead {
  background-color: var(--thead);
  position: sticky;
  left: 0;
}

.rsvp-table th {
  padding: 14px 16px;
  border-bottom: 2px solid var(--border);
  font-weight: 700;
  color: var(--text-900);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  font-size: 0.8em;
  white-space: nowrap;
  background-color: var(--thead);
}

.rsvp-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text-700);
  vertical-align: top;
  transition: background-color 0.2s ease;
  background-color: white;
}

.rsvp-table tbody tr:last-child td { border-bottom: none; }
.rsvp-table tbody tr:hover { background-color: var(--row-hover); }

/* Sticky index + name (chip look like UI) */
.rsvp-table td:first-child {
  text-align: center;
  font-weight: 700;
  width: 56px;
  color: var(--muted-400);
  position: sticky;
  left: 0;
  background-color: white;
  border-right: 1px solid var(--border);
}

.rsvp-table td:nth-child(2) {
  font-weight: 700;
  color: var(--text-900);
  min-width: 120px;
  position: sticky;
  left: 56px;
  background-color: white;
  border-right: 1px solid var(--border);
}

.rsvp-table td:last-child {
  white-space: nowrap;
  font-size: 0.82em;
  color: var(--muted-400);
  min-width: 130px;
}

/* --- NO ENTRIES MESSAGE --- */
.no-rsvp-entries {
  text-align: center;
  color: var(--text-500);
  font-size: 1em;
  padding: 40px 20px;
  background-color: var(--panel-weak);
  border-radius: 10px;
  border: 1px solid var(--border);
  margin: 20px 0;
  font-weight: 500;
  letter-spacing: 0.2px;
}

/* --- PASSWORD FORM (FILTER) --- */
.rsvp-password-form {
  max-width: 90%;
  margin: 60px auto;
  padding: 30px 20px;
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 10px 24px rgba(19,22,30,0.06);
  text-align: center;
  background-color: var(--panel);
}

.rsvp-password-form h2 {
  font-size: 1.5em;
  margin-bottom: 16px;
  font-weight: 700;
  color: var(--text-900);
  letter-spacing: -0.2px;
}

.rsvp-password-form p.hint {
  color: var(--muted-400);
  font-size: 0.92em;
  margin-bottom: 18px;
}

.rsvp-password-form input[type="text"] {
  padding: 12px 15px;
  font-size: 1em;
  border: 1px solid var(--border);
  border-radius: 10px;
  width: 100%;
  margin-bottom: 12px;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  background: var(--panel-weak);
}

.rsvp-password-form input[type="text"]:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(244, 200, 74, 0.18);
  background: #fff;
}

.rsvp-password-form button[type="submit"] {
  padding: 12px 22px;
  font-size: 0.95em;
  background: #9bd6ed;
  color: #0a4157;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  transition: transform 0.08s ease, box-shadow 0.25s ease, background-color 0.25s ease;
  font-weight: 700;
  letter-spacing: 0.2px;
  width: 100%;
  box-shadow: 0 10px 24px rgba(244, 200, 74, 0);
}

.rsvp-password-form button[type="submit"]:hover {
  background: #2d2d2d;
  color: #fff;
}

/* --- SCROLL INDICATOR TEXT (Mobile Only) --- */
@media (max-width: 767px) {
  .rsvp-table-wrapper::before {
    content: "← Swipe untuk melihat kolom →";
    display: block;
    text-align: center;
    padding: 8px;
    font-size: 0.75em;
    color: var(--muted-400);
    background-color: var(--panel-strong);
    border-bottom: 1px solid var(--border);
    letter-spacing: 0.5px;
  }
}

/* --- TABLET --- */
@media (min-width: 768px) {
  .rsvp-container { padding: 0 30px; margin: 60px auto; }
  .rsvp-container h1 { font-size: 2.3em; margin-bottom: 40px; padding-bottom: 15px; }
  .rsvp-info-bar { flex-direction: row; align-items: center; margin-bottom: 25px; gap: 0; }
  .rsvp-info-bar p { font-size: 1em; }
  .rsvp-export-button { width: auto; padding: 10px 22px; font-size: 0.95em; }
  .rsvp-table { font-size: 0.92em; }
  .rsvp-table th { padding: 16px 18px; }
  .rsvp-table td { padding: 16px 18px; }
  .rsvp-table td:first-child, .rsvp-table td:nth-child(2) { position: static; border-right: none; }
  .rsvp-password-form { max-width: 420px; margin: 80px auto; padding: 40px 35px; }
  .rsvp-table-wrapper::before { display: none; }
}

/* --- DESKTOP --- */
@media (min-width: 1024px) {
  .rsvp-container { margin: 80px auto; padding: 0 40px; }
  .rsvp-container h1 { font-size: 2.7em; font-weight: 700; }
  .rsvp-table-wrapper { min-width: auto; overflow-x: visible; background: none; }
  .rsvp-table { min-width: auto; }
}
