/* DMRP Panel — Plus Jakarta Sans, Primary #0B6B6F */
@import url('https://fonts.bunny.net/css?family=plus-jakarta-sans:400,500,600,700');

:root {
  --font: 'Plus Jakarta Sans', system-ui, sans-serif;
  --primary: #0B6B6F;
  --primary-dark: #084F52;
  --primary-light: #E6F4F4;
  --primary-muted: rgba(11, 107, 111, 0.12);
  --accent: #C4A035;
  --accent-soft: #FDF8E8;
  --bg: #F4F7F8;
  --surface: #FFFFFF;
  --border: #E2E8EC;
  --text: #1A2B2E;
  --text-muted: #5C6F73;
  --text-soft: #8A9BA0;
  --success: #1A8F5B;
  --success-bg: #E8F7EF;
  --warning: #B8860B;
  --warning-bg: #FDF6E3;
  --danger: #C73E3E;
  --danger-bg: #FDECEC;
  --info: #2B6CB0;
  --info-bg: #EBF4FF;
  --sidebar-w: 260px;
  --header-h: 64px;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 3px rgba(26, 43, 46, 0.06);
  --shadow-md: 0 8px 24px rgba(26, 43, 46, 0.08);
}

*, *::before, *::after { box-sizing: border-box; }
html { font-size: 15px; -webkit-font-smoothing: antialiased; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
}

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

/* ——— Auth layout ——— */
.auth-wrap {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}
@media (max-width: 900px) {
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
}
.auth-brand {
  background: linear-gradient(145deg, var(--primary-dark) 0%, var(--primary) 50%, #0E8589 100%);
  color: #fff;
  padding: 3rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.auth-brand h1 { font-size: 2rem; font-weight: 700; margin: 0 0 1rem; letter-spacing: -0.02em; }
.auth-brand p { opacity: 0.9; font-size: 1.05rem; max-width: 360px; margin: 0; line-height: 1.6; }
.auth-brand ul { margin: 2rem 0 0; padding: 0; list-style: none; }
.auth-brand li {
  padding: 0.5rem 0;
  padding-left: 1.5rem;
  position: relative;
  opacity: 0.95;
  font-size: 0.95rem;
}
.auth-brand li::before {
  content: '';
  position: absolute;
  left: 0; top: 0.85em;
  width: 6px; height: 6px;
  background: var(--accent);
  border-radius: 50%;
}
.auth-form-side {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: var(--surface);
}
.auth-card { width: 100%; max-width: 400px; }
.auth-card h2 { font-size: 1.5rem; font-weight: 700; margin: 0 0 0.25rem; color: var(--text); }
.auth-card .subtitle { color: var(--text-muted); margin: 0 0 1.75rem; font-size: 0.95rem; }
.auth-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--primary);
  margin-bottom: 2rem;
}
.auth-logo span {
  width: 36px; height: 36px;
  background: var(--primary);
  color: #fff;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
}

/* ——— App shell ——— */
.app { display: flex; min-height: 100vh; }
.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  z-index: 99;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}
.sidebar-overlay.is-visible {
  display: block;
  opacity: 1;
  pointer-events: auto;
}
.sidebar {
  width: var(--sidebar-w);
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  transition: transform 0.25s ease;
}
.sidebar-logo {
  padding: 1rem 1rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}
.sidebar-logo-text {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--primary);
}
.sidebar-close {
  display: none;
  width: 36px;
  height: 36px;
  border: none;
  background: var(--bg);
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
}
.sidebar-close:hover { background: var(--border); color: var(--text); }
.sidebar-logo i {
  width: 32px; height: 32px;
  background: var(--primary);
  color: #fff;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-style: normal;
  font-size: 0.75rem;
  font-weight: 700;
}
.sidebar-nav { flex: 1; overflow-y: auto; padding: 1rem 0.75rem; }
.nav-section {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-soft);
  padding: 1rem 0.75rem 0.35rem;
}
.nav-link {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.9rem;
  margin-bottom: 2px;
  transition: background 0.15s, color 0.15s;
}
.nav-link:hover { background: var(--bg); color: var(--text); }
.nav-link.active {
  background: var(--primary-muted);
  color: var(--primary);
}
.nav-link svg { width: 18px; height: 18px; flex-shrink: 0; opacity: 0.85; }
.sidebar-footer {
  padding: 1rem 1.25rem;
  border-top: 1px solid var(--border);
  font-size: 0.8rem;
  color: var(--text-soft);
}

.main {
  flex: 1;
  margin-left: var(--sidebar-w);
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.topbar {
  height: var(--header-h);
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.5rem;
  position: sticky;
  top: 0;
  z-index: 50;
}
.topbar-left { display: flex; align-items: center; gap: 1rem; }
.topbar h1 { font-size: 1.15rem; font-weight: 600; margin: 0; }
.breadcrumb { font-size: 0.85rem; color: var(--text-muted); }
.breadcrumb a { color: var(--text-muted); }
.topbar-right { display: flex; align-items: center; gap: 0.75rem; }
.hotel-select {
  padding: 0.45rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 0.85rem;
  min-width: 180px;
  background: var(--bg);
}
.user-avatar {
  width: 36px; height: 36px;
  border-radius: 10px;
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.8rem;
  flex-shrink: 0;
}
.profile-menu { position: relative; }
.profile-menu-trigger {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.5rem 0.35rem 0.35rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  cursor: pointer;
  font-family: var(--font);
  text-align: left;
  max-width: 220px;
}
.profile-menu-trigger:hover { background: var(--bg); }
.profile-menu-label {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.25;
}
.profile-menu-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 140px;
}
.profile-menu-email {
  font-size: 0.72rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 140px;
}
.profile-menu-chevron { flex-shrink: 0; color: var(--text-muted); transition: transform 0.15s; }
.profile-menu.is-open .profile-menu-chevron { transform: rotate(180deg); }
.profile-menu-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 200px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 12px 40px rgba(15, 23, 42, 0.12);
  padding: 0.35rem;
  z-index: 120;
}
.profile-menu-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  color: var(--text);
  text-decoration: none;
}
.profile-menu-item svg { width: 18px; height: 18px; flex-shrink: 0; color: var(--text-muted); }
.profile-menu-item:hover { background: var(--bg); }
.profile-menu-item--danger { color: #b91c1c; }
.profile-menu-item--danger svg { color: #b91c1c; }
.profile-menu-divider { height: 1px; background: var(--border); margin: 0.35rem 0; }
.topbar-hotel-wrap { display: flex; align-items: center; }
.profile-meta-list {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 0.5rem 1rem;
  margin: 0;
  font-size: 0.9rem;
}
.profile-meta-list dt { color: var(--text-muted); font-weight: 500; margin: 0; }
.profile-meta-list dd { margin: 0; color: var(--text); }
.content { padding: 1.5rem; flex: 1; }

/* ——— Components ——— */
.page-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.page-header h2 { font-size: 1.35rem; font-weight: 700; margin: 0; }
.page-header p { margin: 0.25rem 0 0; color: var(--text-muted); font-size: 0.9rem; }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 1.25rem;
}
.card-header {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.card-header h3 { margin: 0; font-size: 1rem; font-weight: 600; }
.card-body { padding: 1.25rem; }
.card-footer {
  padding: 1rem 1.25rem;
  border-top: 1px solid var(--border);
  background: var(--bg);
  border-radius: 0 0 var(--radius) var(--radius);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
}
.stat-card .label { font-size: 0.8rem; color: var(--text-muted); font-weight: 500; margin-bottom: 0.35rem; }
.stat-card .value { font-size: 1.75rem; font-weight: 700; color: var(--text); letter-spacing: -0.02em; }
.stat-card .meta { font-size: 0.8rem; color: var(--text-soft); margin-top: 0.35rem; }
.stat-card.primary .value { color: var(--primary); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.55rem 1.1rem;
  font-family: var(--font);
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s;
  text-decoration: none;
  line-height: 1.3;
}
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); color: #fff; }
.btn-secondary { background: var(--bg); color: var(--text); border: 1px solid var(--border); }
.btn-secondary:hover { background: var(--border); color: var(--text); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-sm { padding: 0.35rem 0.75rem; font-size: 0.8rem; }
.btn-ghost { background: transparent; color: var(--text-muted); }
.btn-ghost:hover { background: var(--bg); color: var(--text); }

.form-group { margin-bottom: 1.1rem; }
.form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.35rem;
}
.form-group .hint { font-size: 0.75rem; color: var(--text-soft); margin-top: 0.25rem; }
.form-control {
  width: 100%;
  padding: 0.6rem 0.85rem;
  font-family: var(--font);
  font-size: 0.9rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-muted);
}
select.form-control,
select.select-styled {
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  padding-right: 2.5rem;
  background-color: var(--surface);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%235C6F73' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  background-size: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-weight: 500;
  color: var(--text);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
select.form-control:hover,
select.select-styled:hover {
  border-color: #b8c5ca;
}
select.form-control:focus,
select.select-styled:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-muted);
  outline: none;
}
select.form-control:disabled,
select.select-styled:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}
textarea.form-control { min-height: 100px; resize: vertical; }
.form-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 1rem; }
.form-check { display: flex; align-items: center; gap: 0.5rem; font-size: 0.9rem; }
.form-check input { width: 1rem; height: 1rem; accent-color: var(--primary); }

.alert {
  padding: 0.85rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  margin-bottom: 1rem;
}
.alert-error { background: var(--danger-bg); color: var(--danger); border: 1px solid rgba(199, 62, 62, 0.25); }
.alert-success { background: var(--success-bg); color: var(--success); border: 1px solid rgba(26, 143, 91, 0.25); }
.alert-info { background: var(--info-bg); color: var(--info); }

.table-wrap { overflow-x: auto; }
.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}
.table th {
  text-align: left;
  padding: 0.75rem 1rem;
  font-weight: 600;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
.table tbody tr:hover { background: rgba(11, 107, 111, 0.03); }
.table tbody tr:last-child td { border-bottom: none; }

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.55rem;
  font-size: 0.72rem;
  font-weight: 600;
  border-radius: 100px;
}
.badge-success { background: var(--success-bg); color: var(--success); }
.badge-warning { background: var(--warning-bg); color: var(--warning); }
.badge-danger { background: var(--danger-bg); color: var(--danger); }
.badge-neutral { background: var(--bg); color: var(--text-muted); }
.badge-primary { background: var(--primary-muted); color: var(--primary); }

.empty-state {
  text-align: center;
  padding: 3rem 1.5rem;
  color: var(--text-muted);
}
.empty-state p { margin: 0.5rem 0 0; }

.tabs { display: flex; gap: 0.25rem; border-bottom: 1px solid var(--border); margin-bottom: 1.25rem; }
.tab {
  padding: 0.65rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-muted);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  cursor: pointer;
  background: none;
  border-top: none; border-left: none; border-right: none;
  font-family: var(--font);
}
.tab.active { color: var(--primary); border-bottom-color: var(--primary); }

.review-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.15rem;
  margin-bottom: 0.85rem;
  background: var(--surface);
}
.review-card .meta { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.5rem; display: flex; flex-wrap: wrap; gap: 0.75rem; }
.review-card .text { font-size: 0.95rem; line-height: 1.55; }
.review-reply {
  margin-top: 0.85rem;
  padding: 0.75rem;
  background: var(--primary-light);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
}

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
@media (max-width: 768px) {
  .grid-2 { grid-template-columns: 1fr; }
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-close { display: flex; align-items: center; justify-content: center; }
  .main { margin-left: 0; }
  .menu-toggle { display: flex !important; }
  .topbar {
    flex-wrap: wrap;
    height: auto;
    min-height: var(--header-h);
    padding: 0.65rem 0.75rem;
    gap: 0.5rem;
  }
  .topbar-left {
    flex: 1;
    min-width: 0;
    gap: 0.5rem;
  }
  .topbar-title-wrap { min-width: 0; }
  .topbar h1 {
    font-size: 1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .topbar-right {
    width: 100%;
    flex-wrap: nowrap;
    justify-content: space-between;
    gap: 0.5rem;
  }
  .topbar-hotel-wrap { flex: 1; min-width: 0; }
  .hotel-select {
    width: 100%;
    min-width: 0;
    max-width: none;
    font-size: 0.8rem;
    padding: 0.4rem 0.5rem;
  }
  .profile-menu { flex-shrink: 0; }
  .profile-menu-trigger {
    max-width: none;
    padding: 0.3rem;
    border: none;
    background: transparent;
  }
  .profile-menu-label { display: none; }
  .profile-menu-chevron { display: none; }
  .profile-menu-dropdown {
    right: 0;
    left: auto;
    min-width: 180px;
  }
  .content { padding: 1rem; }
  body.sidebar-open { overflow: hidden; }
}
.menu-toggle {
  display: none;
  width: 40px; height: 40px;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius-sm);
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.2rem;
}

.auth-divider {
  text-align: center;
  margin: 1.25rem 0;
  color: var(--text-soft);
  font-size: 0.8rem;
  position: relative;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 42%;
  height: 1px;
  background: var(--border);
}
.auth-divider::before { left: 0; }
.auth-divider::after { right: 0; }

.progress-bar {
  height: 8px;
  background: var(--bg);
  border-radius: 100px;
  overflow: hidden;
}
.progress-bar span {
  display: block;
  height: 100%;
  background: var(--primary);
  border-radius: 100px;
}

.channel-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.6rem;
  background: var(--bg);
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 500;
}

/* ——— Review Inbox (flagship) ——— */
.inbox-page { --inbox-radius: 16px; max-width: 1120px; margin: 0 auto; }

.inbox-hero {
  position: relative;
  border-radius: var(--inbox-radius);
  padding: 1.75rem 2rem;
  margin-bottom: 1.25rem;
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 45%, #0d8a8f 100%);
  color: #fff;
  overflow: hidden;
  box-shadow: var(--shadow-md);
}
.inbox-hero::before {
  content: '';
  position: absolute;
  right: -40px; top: -60px;
  width: 220px; height: 220px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
}
.inbox-hero::after {
  content: '';
  position: absolute;
  right: 80px; bottom: -80px;
  width: 160px; height: 160px;
  border-radius: 50%;
  background: rgba(196, 160, 53, 0.15);
}
.inbox-hero-inner { position: relative; z-index: 1; display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1.25rem; }
.inbox-hero h2 {
  margin: 0;
  font-size: 1.65rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.inbox-hero h2 svg { opacity: 0.9; }
.inbox-hero p { margin: 0.4rem 0 0; opacity: 0.88; font-size: 0.95rem; max-width: 420px; }
.inbox-hero-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.inbox-hero .btn-export {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(6px);
}
.inbox-hero .btn-export:hover { background: rgba(255, 255, 255, 0.22); color: #fff; }

.inbox-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.65rem;
  margin-bottom: 1.25rem;
}
@media (max-width: 640px) {
  .inbox-tabs { grid-template-columns: repeat(2, 1fr); }
}
.inbox-tab {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 1rem 1.15rem;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--inbox-radius);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.15s;
  box-shadow: var(--shadow);
}
.inbox-tab:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
  color: inherit;
}
.inbox-tab.is-active {
  border-color: var(--primary);
  background: linear-gradient(180deg, var(--primary-light) 0%, var(--surface) 100%);
  box-shadow: 0 4px 16px var(--primary-muted);
}
.inbox-tab-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.inbox-tab-icon svg { width: 22px; height: 22px; }
.inbox-tab-icon--new { background: var(--warning-bg); color: var(--warning); }
.inbox-tab-icon--pending { background: var(--info-bg); color: var(--info); }
.inbox-tab-icon--replied { background: var(--success-bg); color: var(--success); }
.inbox-tab-icon--all { background: var(--primary-muted); color: var(--primary); }
.inbox-tab-label { font-size: 0.78rem; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.04em; }
.inbox-tab-count { font-size: 1.5rem; font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; color: var(--text); }

.inbox-toolbar {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--inbox-radius);
  margin-bottom: 1rem;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.inbox-toolbar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1.15rem;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.inbox-toolbar-head span { font-size: 0.85rem; font-weight: 600; color: var(--text-muted); display: flex; align-items: center; gap: 0.4rem; }
.inbox-toolbar-toggle {
  font-family: var(--font);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--primary);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem 0.5rem;
}
.inbox-filters {
  padding: 1.15rem 1.25rem 1.25rem;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.85rem 1rem;
  align-items: end;
}
.inbox-filters.is-collapsed { display: none; }
.inbox-filters .form-group { margin: 0; }
.inbox-filters .form-group label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-soft); }
.inbox-filters-actions {
  grid-column: 1 / -1;
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  padding-top: 0.25rem;
}

.inbox-chips { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1rem; }
.inbox-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.3rem 0.65rem;
  font-size: 0.78rem;
  font-weight: 600;
  background: var(--primary-muted);
  color: var(--primary);
  border-radius: 100px;
}
.inbox-chip a { color: inherit; opacity: 0.7; font-size: 1rem; line-height: 1; }
.inbox-chip a:hover { opacity: 1; }

.inbox-list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.85rem;
  padding: 0 0.15rem;
}
.inbox-list-header h3 { margin: 0; font-size: 0.95rem; font-weight: 600; color: var(--text-muted); }
.inbox-list-header .count { font-weight: 700; color: var(--text); }

.inbox-item-wrap {
  position: relative;
  margin-bottom: 0.75rem;
}
.inbox-item-wrap--selectable {
  display: flex;
  align-items: stretch;
  gap: 0;
}
.inbox-item-wrap--selectable .inbox-item {
  flex: 1;
  min-width: 0;
  margin-bottom: 0;
  border-radius: 0 var(--inbox-radius) var(--inbox-radius) 0;
}
.inbox-item-select {
  flex: 0 0 2.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-right: none;
  border-radius: var(--inbox-radius) 0 0 var(--inbox-radius);
  cursor: pointer;
  user-select: none;
  transition: background 0.15s, border-color 0.15s;
}
.inbox-item-wrap--selectable:has(.inbox-item-check:checked) .inbox-item-select {
  background: var(--primary-muted);
  border-color: rgba(11, 107, 111, 0.35);
}
.inbox-item-check {
  appearance: none;
  -webkit-appearance: none;
  width: 1.125rem;
  height: 1.125rem;
  margin: 0;
  border: 2px solid var(--border-strong, #c5d0d1);
  border-radius: 5px;
  background: var(--surface);
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
  position: relative;
  vertical-align: middle;
}
.inbox-item-check:hover {
  border-color: var(--primary);
}
.inbox-item-check:checked {
  background: var(--primary);
  border-color: var(--primary);
  box-shadow: 0 0 0 2px var(--primary-muted);
}
.inbox-item-check:checked::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 46%;
  width: 5px;
  height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: translate(-50%, -50%) rotate(45deg);
}
.inbox-item-check:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.inbox-item {
  display: grid;
  grid-template-columns: 4px 1fr auto;
  gap: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--inbox-radius);
  margin-bottom: 0.75rem;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.2s, border-color 0.2s, transform 0.15s;
  box-shadow: var(--shadow);
}
.inbox-item:hover {
  border-color: rgba(11, 107, 111, 0.35);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
  color: inherit;
}
.inbox-item-accent { width: 4px; }
.inbox-item--new .inbox-item-accent { background: linear-gradient(180deg, var(--accent) 0%, var(--warning) 100%); }
.inbox-item--pending .inbox-item-accent { background: linear-gradient(180deg, var(--info) 0%, #4a90d9 100%); }
.inbox-item--replied .inbox-item-accent { background: linear-gradient(180deg, var(--success) 0%, #2db87a 100%); }

.inbox-item-body { padding: 1.15rem 1.25rem; min-width: 0; }
.inbox-item-top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}
.inbox-avatar {
  width: 46px; height: 46px;
  border-radius: 14px;
  background: linear-gradient(145deg, var(--primary-light), #d4eeef);
  color: var(--primary-dark);
  font-weight: 700;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 2px solid var(--surface);
  box-shadow: 0 2px 8px var(--primary-muted);
}
.inbox-item-meta { flex: 1; min-width: 0; }
.inbox-item-meta h4 {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.inbox-item-sub {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  margin-top: 0.3rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}
.inbox-channel {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.inbox-channel--google_business { background: #e8f0fe; color: #1a56db; }
.inbox-channel--booking { background: #e8f4fd; color: #003580; }
.inbox-channel--tripadvisor { background: #e8f7ef; color: #00aa6c; }
.inbox-channel--expedia { background: #fdf6e3; color: #996600; }
.inbox-channel--default { background: var(--bg); color: var(--text-muted); }

.inbox-locale-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.18rem 0.5rem;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 600;
  background: var(--primary-light);
  color: var(--primary-dark);
  border: 1px solid rgba(11, 107, 111, 0.15);
}
.inbox-locale-badge--lang {
  background: var(--accent-soft);
  color: #7a5f10;
  border-color: rgba(196, 160, 53, 0.25);
}

.inbox-status {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
}
.inbox-status--new { background: var(--warning-bg); color: var(--warning); }
.inbox-status--pending { background: var(--info-bg); color: var(--info); }
.inbox-status--replied { background: var(--success-bg); color: var(--success); }

.inbox-item-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 0.4rem;
  line-height: 1.35;
}
.inbox-item-text {
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--text-muted);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.inbox-item-reply {
  margin-top: 0.75rem;
  padding: 0.65rem 0.85rem;
  background: var(--primary-light);
  border-left: 3px solid var(--primary);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.82rem;
  color: var(--primary-dark);
  line-height: 1.45;
}
.inbox-item-reply strong { font-weight: 600; color: var(--primary); }
.inbox-item-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.75rem;
}
.inbox-tag {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  background: var(--bg);
  color: var(--text-muted);
}

.inbox-item-side {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 1rem 1.15rem;
  border-left: 1px solid var(--border);
  background: linear-gradient(180deg, var(--bg) 0%, var(--surface) 100%);
  min-width: 100px;
}
.inbox-score {
  width: 52px; height: 52px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  line-height: 1;
  border: 3px solid var(--border);
  background: var(--surface);
}
.inbox-score-value { font-size: 1.1rem; color: var(--text); }
.inbox-score-label { font-size: 0.6rem; color: var(--text-soft); font-weight: 600; text-transform: uppercase; }
.inbox-score--high { border-color: var(--success); background: var(--success-bg); }
.inbox-score--high .inbox-score-value { color: var(--success); }
.inbox-score--mid { border-color: var(--warning); background: var(--warning-bg); }
.inbox-score--mid .inbox-score-value { color: var(--warning); }
.inbox-score--low { border-color: var(--danger); background: var(--danger-bg); }
.inbox-score--low .inbox-score-value { color: var(--danger); }

.inbox-sentiment {
  text-align: center;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.25rem 0.45rem;
  border-radius: 100px;
  min-width: 48px;
}
.inbox-sentiment--pos { background: var(--success-bg); color: var(--success); }
.inbox-sentiment--neg { background: var(--danger-bg); color: var(--danger); }
.inbox-sentiment--neu { background: var(--bg); color: var(--text-muted); }

.inbox-cta {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 0.25rem;
  white-space: nowrap;
}
.inbox-item:hover .inbox-cta { color: var(--primary-dark); }

.inbox-empty {
  text-align: center;
  padding: 4rem 2rem;
  background: var(--surface);
  border: 2px dashed var(--border);
  border-radius: var(--inbox-radius);
}
.inbox-empty-icon {
  width: 72px; height: 72px;
  margin: 0 auto 1.25rem;
  background: var(--primary-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
}
.inbox-empty h3 { margin: 0 0 0.5rem; font-size: 1.2rem; }
.inbox-empty p { margin: 0; color: var(--text-muted); max-width: 360px; margin-left: auto; margin-right: auto; }

.inbox-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.25rem;
  padding: 1rem 1.15rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--inbox-radius);
}
.inbox-pagination .hint { margin: 0; font-size: 0.85rem; color: var(--text-muted); }
.inbox-pagination-nav { display: flex; gap: 0.4rem; }

@media (max-width: 768px) {
  .inbox-item {
    grid-template-columns: 4px 1fr;
    grid-template-rows: auto auto;
  }
  .inbox-item-accent { grid-row: 1 / span 2; }
  .inbox-item-body { grid-column: 2; grid-row: 1; }
  .inbox-item-side {
    grid-column: 2;
    grid-row: 2;
    flex-direction: row;
    border-left: none;
    border-top: 1px solid var(--border);
    justify-content: flex-start;
    padding: 0.75rem 1.15rem;
  }
  .inbox-hero { padding: 1.35rem 1.25rem; }
}

/* ——— Analytics ——— */
.analytics-page { max-width: 1280px; margin: 0 auto; }

.analytics-hero {
  border-radius: 16px;
  padding: 1.75rem 2rem;
  margin-bottom: 1.25rem;
  background: linear-gradient(120deg, #0a3d40 0%, var(--primary) 50%, #0e9aa0 100%);
  color: #fff;
  box-shadow: var(--shadow-md);
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
}
.analytics-hero h2 { margin: 0; font-size: 1.6rem; font-weight: 700; letter-spacing: -0.03em; }
.analytics-hero p { margin: 0.35rem 0 0; opacity: 0.9; font-size: 0.95rem; }
.analytics-period { display: flex; flex-wrap: wrap; gap: 0.35rem; background: rgba(0,0,0,0.15); padding: 0.25rem; border-radius: 10px; max-width: 100%; justify-content: flex-end; }
.analytics-period a {
  padding: 0.45rem 1rem;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  color: rgba(255,255,255,0.85);
  text-decoration: none;
}
.analytics-period a.is-active { background: #fff; color: var(--primary-dark); }
.analytics-period a:hover:not(.is-active) { color: #fff; }

.analytics-kpis {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}
.analytics-kpi {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.1rem 1.2rem;
  box-shadow: var(--shadow);
}
.analytics-kpi .label { font-size: 0.72rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-soft); }
.analytics-kpi .value { font-size: 1.65rem; font-weight: 700; letter-spacing: -0.02em; margin-top: 0.2rem; color: var(--text); }
.analytics-kpi .value small { font-size: 0.9rem; font-weight: 600; color: var(--text-muted); }
.analytics-kpi--primary { border-color: rgba(11, 107, 111, 0.25); background: linear-gradient(180deg, var(--primary-light) 0%, var(--surface) 100%); }
.analytics-kpi--primary .value { color: var(--primary); }

.analytics-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1rem;
  margin-bottom: 1.25rem;
}
.analytics-chart-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.analytics-chart-card--6 { grid-column: span 6; }
.analytics-chart-card--4 { grid-column: span 4; }
.analytics-chart-card--8 { grid-column: span 8; }
.analytics-chart-card--12 { grid-column: span 12; }
@media (max-width: 1024px) {
  .analytics-chart-card--6,
  .analytics-chart-card--4,
  .analytics-chart-card--8 { grid-column: span 12; }
}
.analytics-chart-head {
  padding: 0.9rem 1.15rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}
.analytics-chart-head h3 { margin: 0; font-size: 0.92rem; font-weight: 600; color: var(--text); }
.analytics-chart-head span { font-size: 0.75rem; color: var(--text-soft); }
.analytics-chart-body {
  padding: 1rem 1.15rem 1.15rem;
  position: relative;
  min-height: 220px;
}
.analytics-chart-body canvas { max-height: 260px; }
.analytics-chart-body--tall { min-height: 280px; }

.analytics-tools {
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  overflow: hidden;
  margin-bottom: 1.25rem;
}
.analytics-tools summary {
  padding: 1rem 1.25rem;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg);
}
.analytics-tools summary::-webkit-details-marker { display: none; }
.analytics-tools-inner {
  padding: 1.25rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  border-top: 1px solid var(--border);
}
.analytics-result {
  margin-top: 1rem;
  padding: 1rem;
  background: var(--primary-light);
  border-radius: var(--radius-sm);
  border-left: 4px solid var(--primary);
}
.analytics-result .big { font-size: 1.35rem; font-weight: 700; color: var(--primary); margin: 0.25rem 0 0; }

.analytics-empty-charts {
  text-align: center;
  padding: 3rem 2rem;
  background: var(--surface);
  border: 2px dashed var(--border);
  border-radius: 14px;
  color: var(--text-muted);
}
