:root {
  --ink: #24171f;
  --muted: #756670;
  --paper: #fffaf8;
  --rose: #ef4f69;
  --rose-deep: #c83050;
  --blush: #fff0f1;
  --line: #eadcdf;
  --night: #180d17;
  --shadow: 0 24px 70px rgba(61, 19, 39, .13);
  font-family: "Manrope", system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; background: var(--paper); }
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
.hidden { display: none !important; }

.site-header {
  height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1280px;
  padding: 0 32px;
  margin: auto;
}

.header-actions { display: flex; align-items: center; gap: 10px; }
.auth-button, .admin-link, .user-menu button { border: 1px solid var(--line); border-radius: 999px; padding: 9px 14px; color: var(--ink); background: white; font-size: 12px; font-weight: 700; }
.admin-link { text-decoration: none; color: var(--rose-deep); }
.auth-button:hover, .admin-link:hover, .user-menu button:hover { border-color: #e88898; background: #fff5f5; }
.user-menu { display: flex; align-items: center; gap: 9px; }
.user-menu span { max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; font-weight: 700; }
.verify-banner { max-width: 1216px; margin: 4px auto 0; padding: 11px 15px; border: 1px solid #f0c8cf; border-radius: 13px; background: #fff1f2; color: #70414e; display: flex; align-items: center; justify-content: center; gap: 12px; font-size: 12px; }
.verify-banner button { border: 0; padding: 0; color: var(--rose-deep); background: transparent; font-weight: 800; text-decoration: underline; }

.brand {
  color: var(--ink);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -.04em;
}

.brand-mark {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  color: white;
  font-size: 16px;
  background: linear-gradient(145deg, #ff8191, #e83e5e);
  box-shadow: 0 7px 16px rgba(232, 62, 94, .22);
}

.expiry-badge {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #735c68;
  background: #fff3f3;
  border: 1px solid #f5dfe1;
  border-radius: 999px;
  padding: 9px 14px;
  font-size: 13px;
  font-weight: 600;
}

.live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--rose); box-shadow: 0 0 0 4px rgba(239, 79, 105, .12); }

.builder-shell {
  max-width: 1280px;
  margin: 0 auto;
  padding: 56px 32px 100px;
  display: grid;
  grid-template-columns: minmax(0, 660px) minmax(350px, 1fr);
  gap: clamp(70px, 9vw, 140px);
  align-items: start;
}

.intro-copy { margin-bottom: 46px; }
.eyebrow { text-transform: uppercase; letter-spacing: .16em; font-size: 11px; font-weight: 700; color: var(--rose-deep); margin: 0 0 16px; }
h1, h2 { font-family: "Prata", Georgia, serif; font-weight: 400; }
h1 { font-size: clamp(40px, 4.8vw, 66px); line-height: 1.06; letter-spacing: -.035em; margin: 0 0 20px; }
h1 em { color: var(--rose-deep); font-style: italic; }
.intro-copy > p:last-child { color: var(--muted); max-width: 560px; line-height: 1.7; font-size: 16px; margin: 0; }

form { display: grid; gap: 28px; }
.form-block { margin: 0; padding: 0; border: 0; display: grid; gap: 18px; }
.form-block legend { width: 100%; padding: 0 0 12px; font-size: 15px; font-weight: 700; display: flex; align-items: center; gap: 10px; }
.form-block legend > span { width: 25px; height: 25px; display: grid; place-items: center; border-radius: 50%; background: var(--ink); color: white; font-size: 12px; }

.type-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.type-card {
  min-height: 105px;
  border: 1px solid var(--line);
  border-radius: 16px;
  color: var(--ink);
  background: white;
  padding: 15px 12px;
  display: grid;
  grid-template-columns: 32px 1fr;
  text-align: left;
  align-items: center;
  column-gap: 8px;
  transition: transform .2s, border-color .2s, box-shadow .2s, background .2s;
}
.type-card:hover { transform: translateY(-2px); border-color: #e6c1c8; box-shadow: 0 10px 26px rgba(80, 27, 49, .08); }
.type-card.active { border-color: #f08a9d; background: #fff5f5; box-shadow: inset 0 0 0 1px #f08a9d; }
.type-card b { grid-row: 1 / 3; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 10px; background: #fff0f1; color: var(--rose); font-size: 18px; }
.type-card span { font-size: 13px; font-weight: 700; align-self: end; }
.type-card small { color: var(--muted); font-size: 11px; align-self: start; }

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field { display: grid; gap: 8px; font-size: 13px; font-weight: 600; }
.field input, .field textarea, .field select {
  width: 100%;
  color: var(--ink);
  background: white;
  border: 1px solid var(--line);
  border-radius: 13px;
  outline: none;
  padding: 13px 14px;
  font-size: 15px;
  line-height: 1.5;
  transition: border-color .2s, box-shadow .2s;
}
.field textarea { resize: vertical; min-height: 92px; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: #e87087; box-shadow: 0 0 0 4px rgba(239, 79, 105, .09); }
.type-fields { display: none; gap: 14px; }
.type-fields.active { display: grid; }
.field-hint { margin: -4px 0 0; color: var(--muted); font-size: 12px; }

.background-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.background-card { position: relative; border: 0; border-radius: 14px; overflow: hidden; height: 104px; background: #291721; padding: 0; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); }
.background-card i { position: absolute; inset: 0; background-image: var(--thumb); background-size: cover; background-position: center; transition: transform .25s; }
.background-card:hover i { transform: scale(1.04); }
.background-card span { position: absolute; left: 8px; right: 8px; bottom: 7px; color: white; font-size: 11px; font-weight: 700; text-shadow: 0 1px 7px rgba(0,0,0,.8); }
.background-card.active::after { content: "✓"; position: absolute; top: 7px; right: 7px; width: 23px; height: 23px; display: grid; place-items: center; background: white; color: var(--rose-deep); border-radius: 50%; font-size: 13px; font-weight: 800; box-shadow: 0 3px 12px rgba(0,0,0,.25); }
.background-card.active { outline: 2px solid var(--rose); outline-offset: 2px; }

.upload-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.upload-card { min-height: 95px; border: 1px dashed #d9c4ca; border-radius: 15px; background: #fffdfc; display: grid; grid-template-columns: 38px 1fr; align-content: center; column-gap: 8px; padding: 14px; cursor: pointer; transition: background .2s, border-color .2s; }
.upload-card:hover { background: #fff5f5; border-color: #e58698; }
.upload-card.locked { cursor: pointer; opacity: .62; filter: saturate(.55); }
.upload-card.locked .upload-icon::after { content: ""; }
.upload-icon { grid-row: 1/3; width: 36px; height: 36px; display: grid; place-items: center; border-radius: 11px; background: #fff0f1; color: var(--rose-deep); font-size: 20px; }
.upload-card b { font-size: 13px; align-self: end; }
.upload-card small { color: var(--muted); font-size: 10px; align-self: start; }
.upload-card input { position: absolute; opacity: 0; pointer-events: none; }
.upload-card.has-file { border-style: solid; border-color: #df8192; background: #fff5f5; }
.upload-access-note { margin: -8px 0 0; color: var(--muted); font-size: 12px; line-height: 1.55; }
.upload-access-note button { border: 0; padding: 0; color: var(--rose-deep); background: transparent; font-weight: 700; text-decoration: underline; }

.toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: white; cursor: pointer; }
.toggle-row > span { display: grid; }
.toggle-row b { font-size: 13px; }
.toggle-row small { color: var(--muted); font-size: 11px; margin-top: 2px; }
.toggle-row input { position: absolute; opacity: 0; }
.toggle-row i { width: 44px; height: 25px; flex: none; border-radius: 999px; background: #d8ccd0; position: relative; transition: background .2s; }
.toggle-row i::after { content: ""; position: absolute; width: 19px; height: 19px; top: 3px; left: 3px; border-radius: 50%; background: white; box-shadow: 0 2px 5px rgba(0,0,0,.2); transition: transform .2s; }
.toggle-row input:checked + i { background: var(--rose); }
.toggle-row input:checked + i::after { transform: translateX(19px); }

.create-button { border: 0; border-radius: 15px; padding: 17px 22px; color: white; background: linear-gradient(135deg, #f45b73, #d73558); display: flex; justify-content: center; align-items: center; gap: 12px; font-weight: 700; font-size: 16px; box-shadow: 0 14px 30px rgba(213, 53, 88, .23); transition: transform .2s, box-shadow .2s; }
.create-button:hover { transform: translateY(-2px); box-shadow: 0 17px 34px rgba(213, 53, 88, .3); }
.create-button:disabled { cursor: wait; opacity: .7; }
.privacy-note { text-align: center; margin: -16px 0 0; color: #8a7a83; font-size: 11px; }

.preview-column { position: sticky; top: 30px; display: grid; justify-items: center; }
.preview-label { width: 340px; display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 14px; }
.preview-label span { font-size: 13px; font-weight: 700; }
.preview-label small { color: var(--muted); font-size: 10px; }
.phone-frame { width: 340px; height: 690px; padding: 9px; border-radius: 48px; background: #171316; box-shadow: 0 40px 90px rgba(50, 16, 35, .26), inset 0 0 0 1px #4c4147; position: relative; }
.phone-speaker { position: absolute; top: 17px; left: 50%; z-index: 5; width: 84px; height: 24px; border-radius: 16px; background: #171316; transform: translateX(-50%); }
.preview-screen { position: relative; width: 100%; height: 100%; border-radius: 40px; overflow: hidden; background-size: cover; background-position: center; color: white; display: grid; grid-template-rows: auto 1fr auto; padding: 36px 24px 22px; isolation: isolate; transition: background-image .3s; }
.bg-night { background-image: url('/assets/night.webp'); }
.bg-roses { background-image: url('/assets/roses.webp'); }
.bg-clouds { background-image: url('/assets/clouds.webp'); color: #3d2935; }
.bg-silk { background-image: url('/assets/silk.webp'); }
.screen-shade { position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(14,7,13,.17), rgba(20,8,15,.3) 68%, rgba(14,7,12,.58)); }
.bg-clouds .screen-shade { background: linear-gradient(180deg, rgba(255,248,247,.13), rgba(255,240,237,.2) 65%, rgba(79,32,48,.26)); }
.preview-brand { text-align: right; opacity: .8; font-size: 9px; letter-spacing: .05em; }
.preview-content { align-self: center; display: grid; justify-items: center; text-align: center; gap: 18px; position: relative; z-index: 2; }
.preview-kicker { font-size: 12px; opacity: .85; }
.preview-content h3 { margin: 0; font-family: "Prata", serif; font-size: 31px; line-height: 1.25; font-weight: 400; white-space: pre-line; text-shadow: 0 2px 20px rgba(0,0,0,.28); }
.preview-content p { margin: 0; max-width: 260px; font-size: 13px; line-height: 1.65; white-space: pre-line; text-shadow: 0 2px 12px rgba(0,0,0,.36); }
.preview-pill { border: 0; border-radius: 999px; color: #4e2734; background: #ffdce1; padding: 12px 24px; font-weight: 700; font-size: 12px; box-shadow: 0 10px 24px rgba(35, 8, 20, .16); }
.preview-photo { width: 180px; height: 180px; border-radius: 28px; object-fit: cover; border: 4px solid rgba(255,255,255,.72); transform: rotate(-2deg); box-shadow: 0 18px 40px rgba(0,0,0,.28); }
.reason-mini { width: 100%; border-radius: 13px; padding: 11px 13px; background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.18); backdrop-filter: blur(10px); font-size: 11px; text-align: left; }
.preview-expiry { justify-self: center; display: flex; align-items: center; gap: 6px; font-size: 9px; opacity: .75; }
.swipe-note { color: var(--muted); font-size: 11px; margin-top: 15px; }

.float-hearts { position: absolute; inset: 0; overflow: hidden; z-index: 1; pointer-events: none; }
.float-hearts i { position: absolute; bottom: -30px; color: #ff6d83; opacity: 0; font-style: normal; animation: floatHeart var(--duration) linear infinite; animation-delay: var(--delay); filter: drop-shadow(0 3px 8px rgba(79,9,31,.25)); }
@keyframes floatHeart { 0% { opacity: 0; transform: translateY(0) rotate(-8deg) scale(.7); } 12% { opacity: .65; } 85% { opacity: .35; } 100% { opacity: 0; transform: translateY(-720px) rotate(18deg) scale(1.1); } }

footer { border-top: 1px solid var(--line); max-width: 1216px; margin: 0 auto; padding: 28px 0 40px; display: flex; align-items: center; justify-content: space-between; gap: 20px; color: var(--muted); font-size: 11px; }
footer > span { color: var(--ink); font-size: 15px; font-weight: 700; }
footer p { margin: 0; font-family: "Prata", serif; font-size: 13px; color: #705b65; }
footer nav { display: flex; align-items: center; gap: 12px; }
footer nav a { color: var(--muted); text-decoration: none; }
footer nav a:hover { color: var(--rose-deep); }

.share-dialog { width: min(540px, calc(100% - 28px)); border: 0; border-radius: 28px; padding: 34px; text-align: center; color: var(--ink); background: #fffaf9; box-shadow: 0 35px 100px rgba(28, 8, 20, .35); }
.share-dialog::backdrop { background: rgba(24, 13, 23, .65); backdrop-filter: blur(5px); }
.dialog-close { position: absolute; top: 15px; right: 15px; width: 34px; height: 34px; border: 0; border-radius: 50%; background: #f3e8e9; color: #7e6871; font-size: 22px; }
.success-mark { margin: 0 auto 18px; width: 62px; height: 62px; display: grid; place-items: center; color: white; background: linear-gradient(145deg, #ff7e91, #dd3b5d); border-radius: 21px; font-size: 27px; box-shadow: 0 12px 28px rgba(221,59,93,.25); }
.share-dialog h2 { font-size: 34px; margin: 3px 0 10px; }
.share-dialog > p:not(.eyebrow) { color: var(--muted); font-size: 14px; line-height: 1.6; }
.link-box, .email-share > div { display: flex; gap: 8px; margin-top: 22px; }
.link-box input, .email-share input { min-width: 0; flex: 1; border: 1px solid var(--line); border-radius: 12px; padding: 12px; background: white; color: var(--ink); }
.link-box button, .email-share button { border: 0; border-radius: 12px; padding: 0 16px; color: white; background: var(--ink); font-weight: 700; font-size: 12px; }
.share-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }
.share-actions a { text-decoration: none; border: 1px solid var(--line); border-radius: 12px; color: var(--ink); background: white; padding: 11px; font-size: 12px; font-weight: 700; }
.email-share { border-top: 1px solid var(--line); margin-top: 22px; padding-top: 19px; text-align: left; }
.email-share label { font-size: 12px; font-weight: 700; }
.email-share > div { margin-top: 9px; }
.share-dialog > small { display: block; color: var(--muted); font-size: 10px; margin-top: 18px; }

.auth-dialog { width: min(470px, calc(100% - 28px)); border: 0; border-radius: 26px; padding: 34px; color: var(--ink); background: #fffaf9; box-shadow: 0 35px 100px rgba(28,8,20,.36); }
.auth-dialog::backdrop { background: rgba(24,13,23,.68); backdrop-filter: blur(6px); }
.auth-close { position: absolute; top: 15px; right: 15px; width: 34px; height: 34px; border: 0; border-radius: 50%; background: #f3e8e9; color: #7e6871; font-size: 22px; }
.auth-heart { width: 54px; height: 54px; display: grid; place-items: center; margin-bottom: 18px; border-radius: 18px; color: white; background: linear-gradient(145deg,#ff7e91,#dd3b5d); box-shadow: 0 10px 24px rgba(221,59,93,.22); font-size: 23px; }
.auth-dialog h2 { margin: 3px 0 8px; font-size: 34px; }
.auth-dialog > p:not(.eyebrow):not(.auth-guest) { margin: 0 0 22px; color: var(--muted); font-size: 13px; line-height: 1.55; }
.auth-dialog form { gap: 14px; }
.auth-consent { display: grid; grid-template-columns: 18px 1fr; gap: 9px; align-items: start; color: var(--muted); font-size: 11px; line-height: 1.5; }
.auth-consent input { width: 17px; height: 17px; accent-color: var(--rose); }
.auth-consent a { color: var(--rose-deep); }
.auth-message { margin: 0; padding: 10px 12px; border-radius: 11px; font-size: 12px; line-height: 1.5; }
.auth-message.error { color: #8d253a; background: #ffe8ec; }
.auth-message.success { color: #356044; background: #eaf8ed; }
.auth-switches { display: flex; align-items: center; justify-content: space-between; margin-top: 17px; gap: 12px; }
.auth-switches button { border: 0; padding: 0; color: var(--rose-deep); background: transparent; font-size: 12px; font-weight: 700; }
.auth-guest { margin: 20px 0 0; padding-top: 16px; border-top: 1px solid var(--line); text-align: center; color: var(--muted); font-size: 11px; }

.legal-app { min-height: 100svh; background: #fffaf8; }
.legal-header { max-width: 980px; margin: auto; padding: 24px 28px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.legal-header > a:last-child { color: var(--rose-deep); text-decoration: none; font-size: 12px; font-weight: 700; }
.legal-shell { width: min(820px, calc(100% - 36px)); margin: 0 auto; padding: 68px 0 90px; }
.legal-shell h1 { max-width: 760px; font-size: clamp(39px, 6vw, 64px); margin-bottom: 12px; }
.legal-updated { margin: 0 0 48px; color: var(--muted); font-size: 13px; }
.legal-shell section { padding: 25px 0; border-top: 1px solid var(--line); }
.legal-shell section h2 { margin: 0 0 11px; font-family: "Manrope", sans-serif; font-size: 17px; font-weight: 700; }
.legal-shell section p { margin: 0; color: #65545e; font-size: 15px; line-height: 1.75; }
.legal-contact { margin-top: 28px; padding: 20px; border-radius: 15px; background: #fff0f1; color: #65434f; font-size: 13px; line-height: 1.7; }
.legal-contact a { color: var(--rose-deep); }

.admin-app { min-height: 100svh; background: linear-gradient(145deg, #fffaf8 0%, #fff4f5 55%, #f8eef3 100%); }
.admin-header { max-width: 1216px; height: 78px; margin: 0 auto; padding: 0 28px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.admin-header > div { display: flex; align-items: center; gap: 14px; }
.admin-header-label { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .12em; }
.admin-header > div a { color: var(--rose-deep); text-decoration: none; font-size: 12px; font-weight: 700; }
.admin-access { min-height: calc(100svh - 78px); display: grid; place-items: center; padding: 32px 18px; }
.admin-access-card { width: min(520px, 100%); padding: 42px; border: 1px solid var(--line); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 28px 80px rgba(82,34,55,.12); }
.admin-access-card h1 { margin: 8px 0 13px; font-size: 45px; }
.admin-access-card > p:not(.eyebrow) { color: var(--muted); line-height: 1.65; }
.admin-access-card .create-button { width: 100%; margin-top: 24px; }
.admin-denied { width: 54px; height: 54px; display: grid; place-items: center; margin-bottom: 18px; border-radius: 18px; color: #a92b48; background: #ffe8ec; font-size: 27px; }
.admin-shell { width: min(1216px, calc(100% - 48px)); margin: 0 auto; padding: 58px 0 90px; }
.admin-page-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: 32px; }
.admin-page-head h1 { margin: 7px 0 10px; font-size: clamp(40px, 6vw, 66px); }
.admin-page-head > div > p:last-child { max-width: 640px; margin: 0; color: var(--muted); line-height: 1.65; }
.admin-secondary { border: 1px solid var(--line); border-radius: 13px; padding: 11px 16px; color: var(--ink); background: white; font-weight: 700; }
.admin-secondary:disabled { opacity: .55; }
.admin-loading, .admin-error { padding: 28px; border: 1px solid var(--line); border-radius: 18px; background: white; color: var(--muted); }
.admin-error { color: #942f45; background: #fff0f2; }
.admin-kpis { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 14px; margin-bottom: 16px; }
.admin-kpis article { min-width: 0; padding: 21px; border: 1px solid var(--line); border-radius: 18px; background: rgba(255,255,255,.88); box-shadow: 0 12px 30px rgba(70,26,46,.05); }
.admin-kpis span, .admin-kpis small { display: block; color: var(--muted); font-size: 11px; }
.admin-kpis strong { display: block; margin: 9px 0 7px; font-family: "Prata", serif; font-size: 32px; font-weight: 400; }
.admin-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 16px; }
.admin-panel { min-width: 0; padding: 24px; border: 1px solid var(--line); border-radius: 20px; background: rgba(255,255,255,.9); box-shadow: 0 12px 30px rgba(70,26,46,.045); }
.admin-panel-title { display: flex; align-items: start; justify-content: space-between; gap: 16px; margin-bottom: 22px; }
.admin-panel-title .eyebrow { margin-bottom: 7px; font-size: 9px; }
.admin-panel-title h2 { margin: 0; font-size: 24px; }
.admin-legend { display: flex; gap: 11px; color: var(--muted); font-size: 10px; }
.admin-legend span { display: flex; align-items: center; gap: 5px; }
.admin-legend i { width: 8px; height: 8px; border-radius: 3px; }
.admin-legend .created, .admin-daily i.created { background: #e64767; }
.admin-legend .viewed, .admin-daily i.viewed { background: #d9a4b3; }
.admin-daily { height: 220px; display: flex; align-items: end; gap: 7px; padding-top: 10px; border-bottom: 1px solid var(--line); }
.admin-daily > div { height: 100%; min-width: 0; flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 7px; }
.admin-daily > div > div { width: 100%; height: calc(100% - 18px); display: flex; align-items: end; justify-content: center; gap: 2px; }
.admin-daily i { width: min(10px, 42%); min-height: 3px; border-radius: 5px 5px 1px 1px; }
.admin-daily small { color: var(--muted); font-size: 9px; }
.admin-progress { display: grid; gap: 15px; }
.admin-progress-row > div { display: flex; justify-content: space-between; gap: 12px; font-size: 12px; }
.admin-progress-row span { color: var(--muted); }
.admin-progress-row p { height: 8px; margin: 7px 0 0; overflow: hidden; border-radius: 8px; background: #f3e8eb; }
.admin-progress-row i { display: block; height: 100%; min-width: 3px; border-radius: inherit; background: linear-gradient(90deg,#f06a80,#d83759); }
.admin-progress.backgrounds i { background: linear-gradient(90deg,#92647b,#4c2d41); }
.admin-empty { color: var(--muted); }
.admin-facts, .admin-system { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.admin-facts > div, .admin-system > div:not(.admin-panel-title) { display: flex; flex-direction: column; padding: 14px; border-radius: 13px; background: #fff6f6; }
.admin-facts strong, .admin-system strong { font-size: 21px; }
.admin-facts span, .admin-system span { margin-top: 4px; color: var(--muted); font-size: 10px; }
.admin-system .admin-panel-title { grid-column: 1/-1; }
.admin-footnote { margin: 18px 0 0; text-align: right; color: var(--muted); font-size: 10px; }

.toast { position: fixed; left: 50%; bottom: 24px; z-index: 100; transform: translate(-50%, 20px); background: #251820; color: white; border-radius: 999px; padding: 11px 18px; font-size: 12px; opacity: 0; pointer-events: none; transition: .25s; box-shadow: 0 12px 30px rgba(0,0,0,.25); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* Public message viewer */
.viewer-app { min-height: 100svh; background: #100a0e; }
.viewer-stage { min-height: 100svh; position: relative; overflow: hidden; color: white; background-size: cover; background-position: center; display: grid; place-items: center; isolation: isolate; }
.viewer-stage.bg-clouds { color: #3d2935; }
.viewer-stage::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(8,5,9,.22), rgba(15,6,12,.48)); }
.viewer-stage.bg-clouds::before { background: linear-gradient(180deg, rgba(255,249,248,.08), rgba(79,34,53,.24)); }
.viewer-top { position: absolute; top: max(20px, env(safe-area-inset-top)); left: 22px; right: 22px; z-index: 5; display: flex; align-items: center; justify-content: space-between; font-size: 11px; opacity: .85; }
.viewer-top a { color: inherit; text-decoration: none; font-weight: 700; }
.viewer-timer { display: flex; align-items: center; gap: 7px; padding: 7px 10px; border-radius: 999px; background: rgba(20,10,16,.28); backdrop-filter: blur(10px); }
.viewer-card { width: min(560px, calc(100% - 36px)); min-height: min(720px, calc(100svh - 96px)); padding: 74px 38px 58px; display: grid; place-items: center; text-align: center; position: relative; z-index: 2; }
.viewer-content { width: 100%; display: grid; justify-items: center; gap: 24px; animation: reveal .65s cubic-bezier(.2,.8,.2,1); }
@keyframes reveal { from { opacity: 0; transform: translateY(12px) scale(.985); } to { opacity: 1; transform: none; } }
.viewer-content h1 { font-size: clamp(36px, 10vw, 64px); line-height: 1.15; margin: 0; color: inherit; text-shadow: 0 3px 24px rgba(0,0,0,.35); white-space: pre-line; }
.viewer-content p { margin: 0; max-width: 500px; font-size: clamp(17px, 4.5vw, 22px); line-height: 1.65; white-space: pre-line; text-shadow: 0 2px 16px rgba(0,0,0,.45); }
.viewer-photo { width: min(330px, 80vw); max-height: 350px; object-fit: cover; border-radius: 28px; border: 5px solid rgba(255,255,255,.7); box-shadow: 0 28px 70px rgba(0,0,0,.35); transform: rotate(-1.5deg); }
.viewer-button { min-width: 150px; border: 0; border-radius: 999px; padding: 15px 25px; color: #4b2230; background: #ffdce2; font-size: 16px; font-weight: 700; box-shadow: 0 13px 30px rgba(31,8,18,.24); transition: transform .2s; }
.viewer-button:hover { transform: translateY(-2px); }
.viewer-button.primary { color: white; background: linear-gradient(135deg, #ff6b82, #e5395d); }
.viewer-actions { width: min(390px, 100%); display: flex; align-items: center; justify-content: center; gap: 12px; min-height: 70px; position: relative; }
.runaway { transition: transform .18s ease-out; }
.taunt { min-height: 22px; font-size: 13px !important; opacity: .86; }
.gift-box { font-size: 110px; filter: drop-shadow(0 20px 30px rgba(0,0,0,.28)); animation: giftPulse 2s ease-in-out infinite; }
@keyframes giftPulse { 0%,100% { transform: scale(1) rotate(-2deg); } 50% { transform: scale(1.06) rotate(2deg); } }
.reason-card { width: min(420px, 100%); min-height: 220px; display: grid; place-items: center; padding: 32px; background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.25); border-radius: 28px; backdrop-filter: blur(18px); box-shadow: 0 28px 70px rgba(10,4,8,.24); }
.bg-clouds .reason-card { background: rgba(255,255,255,.38); border-color: rgba(255,255,255,.5); }
.reason-count { font-size: 11px; opacity: .75; letter-spacing: .1em; text-transform: uppercase; }
.secret-input { width: min(340px, 100%); border: 1px solid rgba(255,255,255,.4); border-radius: 14px; padding: 14px 16px; text-align: center; outline: none; color: white; background: rgba(15,7,12,.25); backdrop-filter: blur(12px); font-size: 17px; }
.bg-clouds .secret-input { color: #3d2935; background: rgba(255,255,255,.36); border-color: rgba(78,38,55,.25); }
.viewer-note { font-size: 12px !important; opacity: .75; }
.audio-toggle { position: absolute; right: 20px; bottom: max(20px, env(safe-area-inset-bottom)); z-index: 6; width: 44px; height: 44px; border: 1px solid rgba(255,255,255,.25); border-radius: 50%; background: rgba(20,9,16,.32); color: white; backdrop-filter: blur(10px); }
.expired-stage { min-height: 100svh; display: grid; place-items: center; padding: 28px; background: radial-gradient(circle at 50% 30%, #43202f, #160d14 62%); color: white; text-align: center; }
.expired-stage > div { max-width: 520px; }
.expired-stage .moon { font-size: 58px; margin-bottom: 20px; }
.expired-stage h1 { font-size: clamp(38px, 9vw, 58px); margin: 0 0 16px; }
.expired-stage p { color: #d9c6ce; line-height: 1.7; }
.expired-stage a { display: inline-block; margin-top: 15px; border-radius: 999px; padding: 14px 22px; color: #3d1b29; background: #ffdce2; text-decoration: none; font-weight: 700; }
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 20; overflow: hidden; }
.confetti i { position: absolute; top: -30px; animation: confettiFall 2.8s ease-in forwards; }
@keyframes confettiFall { to { transform: translate(var(--drift), 110vh) rotate(720deg); opacity: .1; } }

@media (max-width: 900px) {
  .builder-shell { grid-template-columns: 1fr; max-width: 700px; padding-top: 32px; gap: 60px; }
  .preview-column { position: relative; top: 0; grid-row: 1; }
  .editor { grid-row: 2; }
  .intro-copy { text-align: center; }
  .intro-copy > p:last-child { margin-inline: auto; }
  footer { margin: 0 24px; }
}

@media (max-width: 600px) {
  .site-header { height: 64px; padding: 0 18px; }
  .header-actions { gap: 6px; }
  .auth-button, .admin-link, .user-menu button { padding: 8px 10px; }
  .user-menu span { display: none; }
  .expiry-badge { font-size: 0; padding: 9px; }
  .expiry-badge::after { content: "48 часов"; font-size: 11px; }
  .builder-shell { padding: 22px 16px 70px; gap: 44px; }
  h1 { font-size: 42px; }
  .intro-copy { margin-bottom: 34px; }
  .phone-frame { width: min(326px, 92vw); height: 640px; }
  .preview-label { width: min(326px, 92vw); }
  .type-grid { grid-template-columns: 1fr 1fr; }
  .type-card { min-height: 92px; }
  .field-row, .upload-grid { grid-template-columns: 1fr; }
  .background-grid { grid-template-columns: 1fr 1fr; }
  .background-card { height: 116px; }
  .verify-banner { margin: 0 14px; flex-direction: column; gap: 4px; text-align: center; }
  footer { flex-direction: column; text-align: center; margin: 0 16px; }
  footer nav { flex-wrap: wrap; justify-content: center; }
  .share-dialog { padding: 32px 18px 24px; }
  .auth-dialog { padding: 32px 20px 24px; }
  .auth-switches { flex-direction: column; }
  .legal-header { padding: 18px; }
  .legal-header > a:last-child { max-width: 120px; text-align: right; }
  .legal-shell { padding-top: 46px; }
  .link-box { display: grid; }
  .link-box button { padding: 12px; }
  .viewer-card { padding-inline: 20px; }
  .viewer-content { gap: 20px; }
  .admin-header { height: 66px; padding: 0 18px; }
  .admin-header-label { display: none; }
  .admin-shell { width: min(100% - 28px, 680px); padding: 38px 0 65px; }
  .admin-page-head { align-items: start; flex-direction: column; }
  .admin-kpis, .admin-grid { grid-template-columns: 1fr; }
  .admin-kpis { grid-template-columns: 1fr 1fr; }
  .admin-panel { padding: 19px; }
  .admin-panel-title { flex-direction: column; }
  .admin-daily { height: 180px; gap: 4px; }
  .admin-access-card { padding: 30px 22px; }
  .admin-access-card h1 { font-size: 38px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: .01ms !important; }
}
