@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@400;500;600;700&display=swap');

:root {
  --primary: #38d6df;
  --primary-dark: #2bb8c0;
  --primary-light: #7de8ee;
  --primary-glow: rgba(56, 214, 223, 0.4);
  --accent: #ff6b9d;
  --accent-light: #ff9dc0;
  --success: #2ecc71;
  --success-light: #eafaf1;
  --danger: #e74c3c;
  --danger-light: #fdf2f2;
  --warning: #f39c12;
  --text: #2d3436;
  --text-light: #636e72;
  --bg: #fafbfc;
  --bg-card: #ffffff;
  --border: #dfe6e9;
  --border-light: #eef1f3;
  --shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  --shadow-hover: 0 8px 32px rgba(56, 214, 223, 0.2);
  --radius: 1rem;
  --radius-sm: 0.5rem;
}

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

html {
  height: 100%;
}

body {
  font-family: 'Fredoka', system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* ============================================
   TYPOGRAPHY
   ============================================ */

.app-name {
  font-family: 'Fredoka', sans-serif;
  font-weight: 700;
  font-size: 2.2rem;
  background: linear-gradient(135deg, var(--primary) 0%, #6c5ce7 50%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: none;
  filter: drop-shadow(0 2px 4px var(--primary-glow));
  letter-spacing: -0.5px;
}

.app-name-hero {
  font-family: 'Fredoka', sans-serif;
  font-weight: 700;
  font-size: 4rem;
  background: linear-gradient(135deg, var(--primary) 0%, #6c5ce7 50%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 4px 8px var(--primary-glow));
  letter-spacing: -1px;
}

h1 {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--text);
}

h2 {
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

h3 {
  font-size: 1.1rem;
  font-weight: 600;
}

a {
  color: var(--primary-dark);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: var(--accent);
}

/* ============================================
   NAVIGATION
   ============================================ */

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1.5rem;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 8px rgba(0, 0, 0, 0.04);
  flex-shrink: 0;
  z-index: 100;
}

.nav-left, .nav-center, .nav-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo-group {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.logo-group img {
  height: 64px;
  width: 64px;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.75rem;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-light);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: all 0.2s;
}

.nav-link:hover {
  color: var(--text);
  background: var(--border-light);
}

.nav-link svg {
  width: 18px;
  height: 18px;
}

.nav-admin {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  padding-right: 0.5rem;
  margin-right: 0.5rem;
  border-right: 1px solid var(--border);
}

.nav-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  color: var(--text-light);
  transition: all 0.2s;
}

.nav-icon:hover {
  color: var(--text);
  background: var(--border-light);
}

.nav-icon svg {
  width: 20px;
  height: 20px;
}

/* Profile dropdown */
.profile-dropdown {
  position: relative;
}

.profile-trigger {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  color: var(--text-light);
  transition: all 0.2s;
  list-style: none;
}

.profile-trigger::-webkit-details-marker {
  display: none;
}

.profile-trigger::marker {
  display: none;
  content: "";
}

.profile-trigger:hover {
  color: var(--text);
  background: var(--border-light);
}

.profile-trigger svg {
  width: 28px;
  height: 28px;
}

.profile-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 0.5rem);
  min-width: 220px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  z-index: 200;
  overflow: hidden;
}

.profile-menu-header {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border-light);
}

.profile-email {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
}

.profile-role {
  display: block;
  font-size: 0.75rem;
  color: var(--text-light);
  margin-top: 0.15rem;
}

.profile-menu-actions {
  padding: 0.5rem;
}

.profile-menu-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.5rem 0.75rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-light);
  border-radius: var(--radius-sm);
  transition: all 0.2s;
  text-align: left;
}

.profile-menu-item:hover {
  color: var(--text);
  background: var(--border-light);
}

.profile-menu-item svg {
  width: 16px;
  height: 16px;
}

/* ============================================
   MAIN CONTENT
   ============================================ */

main {
  flex: 1;
  min-height: 0;
  overflow: hidden;
  display: flex;
  justify-content: center;
}

.main-content {
  flex: 1;
  max-width: 960px;
  width: 100%;
  padding: 0.75rem 2rem 2rem;
  overflow-y: auto;
  scrollbar-width: none;
  display: flex;
  flex-direction: column;
}

.main-content::-webkit-scrollbar {
  display: none;
}

/* ============================================
   BUTTONS
   ============================================ */

button,
input[type="button"] {
  background: transparent;
  border: 0;
  cursor: pointer;
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
}

form.button_to {
  margin: 0;
  padding: 0;
  display: inline;
}

.primary,
a.primary,
button.primary,
input[type="submit"] {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  font-weight: 700;
  padding: 0.5rem 1.25rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  border: 0;
  color: white;
  background: linear-gradient(135deg, var(--primary), #6c5ce7);
  box-shadow: 0 4px 20px var(--primary-glow);
  transition: all 0.3s;
  cursor: pointer;
}

.primary:hover,
a.primary:hover,
button.primary:hover,
input[type="submit"]:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(56, 214, 223, 0.4);
  color: white;
}

.primary svg {
  width: 16px;
  height: 16px;
}

.secondary,
a.secondary,
button.secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.5rem 1rem;
  text-decoration: none;
  font-weight: 600;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  color: var(--text-light);
  background: var(--border-light);
  border: 1px solid var(--border);
  transition: all 0.2s;
  cursor: pointer;
}

.secondary:hover,
a.secondary:hover,
button.secondary:hover {
  background: var(--border);
  color: var(--text);
  transform: translateY(-1px);
}

.secondary svg {
  width: 16px;
  height: 16px;
}

.danger,
button.danger {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.5rem 1rem;
  color: var(--danger);
  background: var(--danger-light);
  border: 1px solid #f5c6cb;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s;
}

.danger:hover,
button.danger:hover {
  background: var(--danger);
  color: white;
  transform: translateY(-1px);
}

.danger svg {
  width: 16px;
  height: 16px;
}

button:disabled,
button[disabled],
input[type="submit"]:disabled {
  background: var(--border);
  color: var(--text-light);
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}

/* ============================================
   FORMS
   ============================================ */

form {
  display: inline;
}

label {
  font-weight: 600;
  margin-top: 1rem;
  display: block;
  color: var(--text);
  font-size: 0.9rem;
}

input[type="email"],
input[type="password"],
input[type="text"],
input[type="number"],
select {
  display: block;
  padding: 0.6rem 0.8rem;
  margin-top: 0.35rem;
  width: 100%;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-family: inherit;
  box-sizing: border-box;
  transition: border-color 0.2s, box-shadow 0.2s;
  background: var(--bg-card);
}

select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23636e72' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  padding-right: 2.25rem;
  cursor: pointer;
}

input[type="email"]:focus,
input[type="password"]:focus,
input[type="text"]:focus,
input[type="number"]:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

textarea {
  display: block;
  padding: 0.6rem 0.8rem;
  margin-top: 0.35rem;
  width: 100%;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-family: inherit;
  box-sizing: border-box;
  min-height: 5rem;
  resize: vertical;
  transition: border-color 0.2s, box-shadow 0.2s;
  background: var(--bg-card);
}

fieldset {
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  margin: 1rem 0 0;
}

fieldset legend {
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-light);
  padding: 0 0.5rem;
}

/* ============================================
   CARDS
   ============================================ */

/* Card, tab, disclosure, file grid, and file preview styles moved to
   shares/ ViewComponent sidecar CSS files. */

/* Drop zone, file list, and file entry styles moved to
   shares/new_form_component.css */

/* ============================================
   FLASH MESSAGES
   ============================================ */

.flash-notice {
  padding: 0.75rem 1rem;
  background: var(--success-light);
  color: #27ae60;
  border: 1px solid #a3d9b1;
  border-radius: var(--radius-sm);
  font-weight: 600;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.flash-alert {
  padding: 0.75rem 1rem;
  background: var(--danger-light);
  color: var(--danger);
  border: 1px solid #f5c6cb;
  border-radius: var(--radius-sm);
  font-weight: 600;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* ============================================
   AUTH PAGES
   ============================================ */

.auth-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 70vh;
  padding: 2rem;
}

.auth-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 2rem;
}

.auth-header img {
  width: 280px;
  height: auto;
  margin-bottom: 0;
  filter: drop-shadow(0 4px 12px var(--primary-glow));
}

.auth-card {
  width: 100%;
  max-width: 420px;
  padding: 2rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.auth-card-logo {
  text-align: center;
  margin-bottom: 1.5rem;
}

.auth-card-logo img {
  width: 320px;
  height: auto;
  filter: drop-shadow(0 4px 12px var(--primary-glow));
}

.auth-card form {
  display: block;
}

.auth-card .actions {
  display: flex;
  justify-content: center;
  margin-top: 1.5rem;
}

.auth-card .actions input[type="submit"] {
  width: 100%;
}

.auth-card .links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-light);
}

.auth-card .links a {
  font-size: 0.9rem;
  color: var(--text-light);
}

.auth-card .links a:hover {
  color: var(--primary-dark);
}

/* ============================================
   HERO / LANDING PAGE
   ============================================ */

.hero {
  text-align: center;
  padding: 0.35rem 1rem 1.5rem;
}

.hero img {
  width: 280px;
  height: auto;
  margin-bottom: 1rem;
  filter: drop-shadow(0 8px 24px var(--primary-glow));
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.hero .tagline {
  font-size: 1.3rem;
  color: var(--text-light);
  margin-top: 0.5rem;
  margin-bottom: 2rem;
}

.policy-hero {
  margin-top: -1rem;
  padding-top: 0;
  padding-bottom: 0.65rem;
}

.policy-hero h1 {
  margin-bottom: 0.2rem;
}

.policy-hero .tagline {
  margin-top: 0.1rem;
  margin-bottom: 0.45rem;
  font-size: 1.08rem;
}

.hero .cta {
  padding: 0.85rem 2rem;
  font-size: 1.1rem;
}

.policy-section {
  --policy-v-gap: 1rem;
  max-width: 1180px;
  margin: 0 auto 2.3rem;
  padding: 1rem 1.25rem 1.25rem;
  background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  box-shadow: 0 6px 24px rgba(45, 52, 54, 0.06);
  display: flex;
  flex-wrap: wrap;
  row-gap: var(--policy-v-gap);
  column-gap: 1rem;
}

.policy-section h2 {
  margin: 0;
  line-height: 1.15;
}

.policy-section > h2,
.policy-section > .policy-summary {
  flex: 1 1 100%;
}

.policy-summary {
  font-size: 1.02rem;
  color: #4e5a5d;
  margin: 0;
  margin-top: -0.45rem;
  line-height: 1.25;
}

.policy-point {
  flex: 1 1 calc((100% - 2rem) / 3);
  min-width: 260px;
  padding: 0.95rem 1rem;
  border-radius: 0.8rem;
  border: 1px solid rgba(56, 214, 223, 0.2);
  background: linear-gradient(135deg, rgba(56, 214, 223, 0.08), rgba(255, 255, 255, 1));
}

.policy-point h3 {
  font-size: 1.05rem;
  margin-bottom: 0.2rem;
}

.policy-point-summary {
  color: #5f6b6f;
  font-size: 0.94rem;
  margin-bottom: 0.55rem;
}

.policy-point p + p {
  margin-top: 0.85rem;
}

.policy-last-updated {
  max-width: 1180px;
  margin: 0.25rem auto 0;
  padding: 0 1.25rem;
  font-size: 0.82rem;
  color: #7b8589;
  text-align: right;
}

.policy-point-upcoming {
  position: relative;
  isolation: isolate;
  flex-basis: 100%;
  border-color: rgba(108, 92, 231, 0.3);
  background: linear-gradient(120deg, rgba(56, 214, 223, 0.18) 0%, rgba(108, 92, 231, 0.16) 45%, rgba(255, 107, 157, 0.12) 72%, rgba(255, 255, 255, 1) 100%);
  background-size: 220% 220%;
  box-shadow: 0 10px 26px rgba(56, 214, 223, 0.2);
  animation: soon-bgshift 8s ease-in-out infinite;
}

.policy-point-upcoming::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: conic-gradient(from 220deg, rgba(56, 214, 223, 0.36), rgba(108, 92, 231, 0.34), rgba(255, 107, 157, 0.3), rgba(56, 214, 223, 0.36));
  z-index: -1;
  opacity: 0.45;
}

.coming-soon-title {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.7rem;
  flex-wrap: wrap;
  line-height: 1;
}

.coming-soon-mark {
  display: inline-flex;
  align-items: flex-end;
  gap: 0.35rem;
  line-height: 1;
  vertical-align: baseline;
}

.coming-soon-inline {
  gap: 0.2rem;
  white-space: nowrap;
  vertical-align: baseline;
}

.snorb-word {
  font-family: 'Fredoka', sans-serif;
  font-weight: 700;
  font-size: 1.22rem;
  line-height: 1em;
  display: inline-block;
  vertical-align: baseline;
  position: relative;
  top: 0.08em;
  background: linear-gradient(135deg, var(--primary) 0%, #6c5ce7 50%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 1px 3px var(--primary-glow));
}

.sub-product-word {
  font-weight: 700;
  font-size: 1.03rem;
  line-height: 1em;
  display: inline-block;
  vertical-align: baseline;
  color: #1f2f33;
  letter-spacing: 0.02em;
}

.coming-soon-badge {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #ffffff;
  background: linear-gradient(120deg, var(--primary-dark) 0%, #6c5ce7 55%, var(--accent) 100%);
  box-shadow: 0 0 0 0 rgba(56, 214, 223, 0.45);
  overflow: hidden;
  animation: soon-pulse 2.2s ease-in-out infinite;
}

.coming-soon-badge::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-120%) skewX(-22deg);
  background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.36) 45%, transparent 100%);
  animation: soon-shimmer 2.2s ease-in-out infinite;
}

@keyframes soon-pulse {
  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(56, 214, 223, 0.45);
  }
  50% {
    transform: scale(1.04);
    box-shadow: 0 0 0 7px rgba(56, 214, 223, 0);
  }
}

@keyframes soon-shimmer {
  0%,
  20% {
    transform: translateX(-120%) skewX(-22deg);
  }
  60%,
  100% {
    transform: translateX(140%) skewX(-22deg);
  }
}

@keyframes soon-bgshift {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

@media (max-width: 980px) {
  .policy-point {
    flex-basis: calc((100% - 1rem) / 2);
  }
}

@media (max-width: 680px) {
  .policy-point {
    flex-basis: 100%;
    min-width: 0;
  }
}

/* ============================================
   PRICING PAGE
   ============================================ */

.pricing-hero {
  padding-top: 0.55rem;
  padding-bottom: 1.05rem;
}

.pricing-hero h1 {
  margin-bottom: 0.15rem;
}

.pricing-hero .tagline {
  max-width: 700px;
  margin: 0 auto 0;
  font-size: 1.08rem;
}

.pricing-page {
  max-width: 1180px;
  margin: 0 auto 1.5rem;
  padding: 0 1.25rem 1.25rem;
}

.plan-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 0.75rem;
}

.plan-grid-coming {
  margin-top: 1.2rem;
}

.plan-card {
  position: relative;
  --plan-pad: 1.05rem;
  min-width: 0;
  background: linear-gradient(170deg, #ffffff 0%, #f7fcfd 100%);
  border: 1px solid var(--border-light);
  border-radius: 1rem;
  padding: var(--plan-pad);
  box-shadow: 0 8px 28px rgba(45, 52, 54, 0.08);
  display: flex;
  flex-direction: column;
  overflow: visible;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.plan-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 34px rgba(56, 214, 223, 0.2);
}

.plan-free,
.plan-paid {
  border-color: rgba(56, 214, 223, 0.55);
  background: linear-gradient(155deg, rgba(56, 214, 223, 0.22) 0%, rgba(108, 92, 231, 0.1) 58%, #ffffff 100%);
}

.plan-badge {
  position: absolute;
  top: -0.72rem;
  left: 50%;
  transform: translateX(-50%);
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 700;
  color: white;
  background: linear-gradient(120deg, var(--primary-dark), #6c5ce7);
  box-shadow: 0 8px 18px rgba(56, 214, 223, 0.35);
}

.plan-badge-support {
  background: linear-gradient(120deg, var(--primary), #6c5ce7 55%, var(--accent));
}

.plan-badge-coming {
  background: linear-gradient(120deg, #6c5ce7, var(--accent));
}

.plan-header {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 0.75rem;
}

.plan-header-top {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.plan-mark {
  width: 42px;
  height: 42px;
  border-radius: 0.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: white;
  background: linear-gradient(135deg, var(--primary-dark), #6c5ce7);
  box-shadow: 0 8px 18px rgba(56, 214, 223, 0.28);
}

.plan-mark svg {
  width: 20px;
  height: 20px;
}

.plan-header h2 {
  margin: 0;
  font-size: 1.28rem;
}

.plan-subtitle {
  color: var(--text-light);
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.35;
}

.plan-features {
  list-style: none;
  display: grid;
  gap: 0.6rem;
  margin-top: 0.15rem;
}

.plan-features li {
  display: flex;
  gap: 0.55rem;
  align-items: flex-start;
  color: #334146;
  line-height: 1.35;
  font-size: 0.95rem;
}

.plan-check {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #1f8e95;
  background: rgba(56, 214, 223, 0.16);
  border: 1px solid rgba(56, 214, 223, 0.28);
}

.plan-check svg {
  width: 12px;
  height: 12px;
}

.pricing-footnote {
  margin-top: 0.9rem;
  color: #637073;
  text-align: center;
  font-size: 0.86rem;
}

@media (max-width: 980px) {
  .plan-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .pricing-page {
    padding-left: 0.95rem;
    padding-right: 0.95rem;
  }

  .plan-card {
    min-width: 0;
  }

  .plan-grid {
    grid-template-columns: 1fr;
  }

  .plan-badge {
    top: -0.6rem;
  }
}

.features {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-top: 3rem;
  justify-content: center;
}

.feature-card {
  flex: 1 1 260px;
  max-width: 320px;
  padding: 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-align: center;
  transition: all 0.3s;
}

.feature-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-4px);
  border-color: var(--primary-light);
}

.feature-card .icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  margin-bottom: 1rem;
  box-shadow: 0 4px 12px var(--primary-glow);
}

.feature-card .icon svg {
  width: 28px;
  height: 28px;
  color: white;
}

.feature-card .icon.teal {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
}

.feature-card .icon.purple {
  background: linear-gradient(135deg, #a29bfe, #6c5ce7);
}

.feature-card .icon.pink {
  background: linear-gradient(135deg, var(--accent-light), var(--accent));
}

.feature-card h3 {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
  color: var(--text);
}

.feature-card p {
  font-size: 0.95rem;
  color: var(--text-light);
  line-height: 1.5;
}

/* Empty state and share form styles moved to
   shares/new_form_component.css */

.share-list-section h2 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.share-list-section h2 svg {
  width: 22px;
  height: 22px;
  color: var(--primary-dark);
}

/* ============================================
   PUBLIC SHARE PAGE
   ============================================ */

.public-share {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 3rem 1rem;
}

.public-share .card {
  max-width: 560px;
  width: 100%;
  padding: 1.5rem 2rem;
}

.public-share .card h2 {
  font-size: 1.2rem;
  color: var(--text-light);
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.public-share .card h3 {
  font-size: 1.5rem;
  margin-bottom: 0.25rem;
}

.public-share .card .file-info {
  color: var(--text-light);
  font-size: 0.8rem;
  margin: 0;
}

.public-share .file-list li {
  gap: 0.5rem;
}

.public-share .file-list .file-info {
  margin-right: 0.25rem;
}

.public-share .file-list .download-btn {
  padding: 0.25rem 0.6rem;
  font-size: 0.8rem;
  gap: 0.25rem;
  color: var(--primary-dark);
  background: rgba(56, 214, 223, 0.1);
  border-color: rgba(56, 214, 223, 0.3);
}

.public-share .file-list .download-btn:hover {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.public-share .file-list .download-btn svg {
  width: 14px;
  height: 14px;
}

/* ============================================
   PAGE TITLES
   ============================================ */

.page-title {
  text-align: center;
  margin-bottom: 1.5rem;
}

/* ============================================
   ADMIN TABLES
   ============================================ */

.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  font-size: 0.9rem;
}

.admin-table thead {
  background: var(--bg);
  border-bottom: 2px solid var(--border);
}

.admin-table th {
  padding: 0.6rem 0.75rem;
  text-align: left;
  font-weight: 600;
  font-size: 0.8rem;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.admin-table td {
  padding: 0.6rem 0.75rem;
  border-top: 1px solid var(--border-light);
  color: var(--text);
  vertical-align: middle;
}

.admin-table tbody tr {
  transition: background 0.15s;
}

.admin-table tbody tr:hover {
  background: var(--border-light);
}

.admin-table .table-meta {
  color: var(--text-light);
  font-size: 0.85rem;
}

.admin-table .actions-col {
  text-align: right;
  white-space: nowrap;
}

/* Icon-only action buttons in table rows */
.table-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: var(--radius-sm);
  color: var(--text-light);
  transition: all 0.2s;
  text-decoration: none;
  vertical-align: middle;
}

.table-action:hover {
  color: var(--text);
  background: var(--border);
}

.table-action svg {
  width: 16px;
  height: 16px;
}

.table-action-danger:hover {
  color: var(--danger);
  background: var(--danger-light);
}

/* Clickable file link in tables */
.table-file-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  color: var(--text);
  font-weight: 500;
}

.table-file-link:hover {
  color: var(--primary-dark);
}

.table-file-link svg {
  width: 18px;
  height: 18px;
  color: var(--primary-dark);
  flex-shrink: 0;
}

/* Status badges */
.status-complete {
  color: var(--success);
  font-weight: 600;
  font-size: 0.85rem;
}

.status-progress {
  color: var(--warning);
  font-weight: 600;
  font-size: 0.85rem;
}

/* ============================================
   SETTINGS PAGE
   ============================================ */

.settings-page {
  display: flex;
  justify-content: center;
  padding: 2rem 0;
}

.settings-card {
  width: 100%;
  max-width: 560px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 2rem;
}

.settings-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-light);
}

.settings-header svg {
  width: 28px;
  height: 28px;
  color: var(--primary-dark);
}

.settings-header h1 {
  margin: 0;
  font-size: 1.5rem;
}

.settings-form {
  display: block;
}

.settings-section {
  margin-bottom: 1.5rem;
}

.settings-section h3 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-light);
  margin-bottom: 1rem;
}

.settings-field {
  display: flex;
  align-items: baseline;
  gap: 1rem;
}

.settings-field label {
  margin-top: 0;
  white-space: nowrap;
  flex-shrink: 0;
  min-width: 8rem;
}

.settings-input-row {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  flex: 1;
}

.settings-input-row input {
  max-width: 8rem;
}

.settings-hint {
  font-size: 0.85rem;
  color: var(--text-light);
}

.settings-actions {
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-light);
}

.settings-input-row select {
  max-width: 10rem;
}

/* ============================================
   USER PROFILE
   ============================================ */

.user-profile {
  display: flex;
  justify-content: center;
  padding: 1rem 0;
}

.user-profile-card {
  width: 100%;
  max-width: 560px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 2rem;
}

.user-profile-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-light);
}

.user-profile-header h1 {
  margin: 0;
  font-size: 1.35rem;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-profile-detail {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--text-light);
  margin-bottom: 0.5rem;
}

.user-profile-detail svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.user-profile-actions {
  display: flex;
  gap: 0.5rem;
  padding-top: 1.25rem;
  margin-top: 1.25rem;
  border-top: 1px solid var(--border-light);
}

.role-badge {
  display: inline-block;
  padding: 0.15rem 0.6rem;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: 1rem;
}

.role-badge--admin {
  background: rgba(56, 214, 223, 0.15);
  color: var(--primary-dark);
}

.role-badge--user {
  background: var(--border-light);
  color: var(--text-light);
}

/* ============================================
   PREVIEW MODAL
   ============================================ */

dialog[data-preview-target="dialog"] {
  border: none;
  border-radius: var(--radius);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.2);
  padding: 0;
  width: 90vw;
  max-width: 900px;
  max-height: 85vh;
  background: var(--bg-card);
  overflow: hidden;
  /* margin: auto keeps the browser's native centering for showModal() */
  margin: auto;
}

dialog[data-preview-target="dialog"][open] {
  display: flex;
  flex-direction: column;
}

dialog[data-preview-target="dialog"]::backdrop {
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
}

.preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border-light);
  background: var(--bg);
  flex-shrink: 0;
}

.preview-title {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  flex: 1;
}

.preview-close {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  color: var(--text-light);
  border-radius: var(--radius-sm);
  transition: all 0.2s;
  margin-left: 0.5rem;
}

.preview-close:hover {
  color: var(--text);
  background: var(--border-light);
}

.preview-progress {
  height: 3px;
  background: var(--border-light);
  flex-shrink: 0;
}

.preview-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--primary-dark));
  transition: width 0.3s ease;
  width: 0%;
}

.preview-progress-label {
  display: block;
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-light);
  padding: 0.25rem 0;
  flex-shrink: 0;
}

.preview-content {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: auto;
  padding: 1rem;
  min-height: 200px;
}

.preview-image {
  max-width: 100%;
  max-height: 70vh;
  object-fit: contain;
  border-radius: var(--radius-sm);
}

.preview-audio {
  width: 100%;
  max-width: 500px;
}

.preview-video {
  max-width: 100%;
  max-height: 70vh;
  border-radius: var(--radius-sm);
}

.preview-pdf {
  width: 100%;
  height: 70vh;
  border: none;
  border-radius: var(--radius-sm);
}

.preview-text {
  width: 100%;
  max-height: 70vh;
  overflow: auto;
  padding: 1rem;
  background: #f8f9fa;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: 0.85rem;
  line-height: 1.5;
  color: var(--text);
  white-space: pre-wrap;
  word-wrap: break-word;
  tab-size: 2;
}

.preview-details {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-top: 1px solid var(--border-light);
  background: var(--bg);
  flex-shrink: 0;
  font-size: 0.8rem;
  color: var(--text-light);
}

.preview-fallback {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  padding: 2rem;
  text-align: center;
}

.preview-fallback-icon {
  font-size: 4rem;
  line-height: 1;
  color: var(--text-light);
}

.preview-fallback-icon svg {
  width: 64px;
  height: 64px;
}

.preview-fallback-name {
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--text);
  word-break: break-all;
}

.preview-fallback-meta {
  font-size: 0.85rem;
  color: var(--text-light);
}

/* File list items (used on share show and public share) */
.file-list {
  list-style: none;
  margin: 1rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.file-list li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 0.75rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: all 0.2s;
}

.file-list li svg {
  width: 20px;
  height: 20px;
  color: var(--primary-dark);
  flex-shrink: 0;
}

.file-list .file-name {
  flex: 1;
  font-weight: 500;
  font-size: 0.9rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.file-list .file-info {
  font-size: 0.8rem;
  color: var(--text-light);
  flex-shrink: 0;
}

.file-list .file-preview-link {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  min-width: 0;
  text-decoration: none;
  color: inherit;
}

.file-list .file-preview-link:hover .file-name {
  color: var(--primary-dark);
}

.file-list .download-btn {
  flex-shrink: 0;
}

/* ============================================
   UTILITIES
   ============================================ */

.icon-inline {
  display: inline-block;
  vertical-align: middle;
  width: 1em;
  height: 1em;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-weight: normal;
}

.checkbox-label input[type="checkbox"] {
  width: auto;
  margin: 0;
}

/* ============================================
   RESPONSIVE
   ============================================ */

/* Compact form field styles moved to shares/form_fields_component.css */

@media (max-width: 600px) {
  .app-name-hero { font-size: 2.5rem; }
  .hero .tagline { font-size: 1.1rem; }
  .features { flex-direction: column; align-items: center; }
  .feature-card { max-width: 100%; }
  nav { padding: 0.5rem 1rem; }
  .nav-center { gap: 0.25rem; }
  .nav-link { padding: 0.3rem 0.5rem; font-size: 0.8rem; }
  .nav-admin { padding-right: 0.25rem; margin-right: 0.25rem; }
  .auth-container { min-height: 60vh; padding: 1rem; }
}
