/* Povod compact interface. Illustration geometry remains in the template system. */
:root { --ui-line: #e8e5df; --ui-paper: #fffefd; --ui-muted: #77736e; }
html { scroll-padding-top: 20px; scroll-padding-bottom: 100px; }
body, body.theme-blue, body.theme-beige, body.theme-neutral, body.theme-green { background: #faf9f6; }
body::before, body.theme-green::before { display: none; }
.shell { width: min(1120px, 100%); padding: calc(16px + var(--app-safe-top, env(safe-area-inset-top))) 24px 24px; }
.topbar { min-height: 60px; margin-bottom: 24px; padding: 8px 0; background: transparent; border: 0; box-shadow: none; backdrop-filter: none; border-radius: 0; }
.brand { gap: 8px; }.brand-mark img { width: 38px; height: 38px; }.brand-mark { width: 38px; height: 38px; }
.top-actions { gap: 8px; }.top-actions .btn-soft { box-shadow: none; min-height: 40px; padding: 8px 14px; border-color: var(--ui-line); }
.btn { min-height: 44px; padding: 10px 18px; border-radius: 14px; box-shadow: none; transition: background-color .16s, border-color .16s, color .16s, transform .16s; touch-action: manipulation; }
.btn:hover { transform: none; }.btn:active { transform: scale(.98); }
.btn-soft { background: #fff; border: 1px solid var(--ui-line); box-shadow: none; }
.btn-accent, body.theme-green .btn-accent { background: var(--primary); color: #fff; box-shadow: none; }
.btn-accent:hover, body.theme-green .btn-accent:hover { background: var(--primary-hover); box-shadow: none; }
.btn-small { min-height: 40px; padding: 8px 12px; }
button, a, summary { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, summary:focus-visible { outline: 3px solid var(--primary); outline-offset: 3px; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; box-shadow: none; }
h1,h2,h3 { text-wrap: balance; } input,select,textarea { font-size: 16px; }
.welcome-layout { display: grid; grid-template-columns: 1.1fr 1fr; gap: 64px; align-items: center; min-height: min(680px,calc(100svh - 150px)); max-width: 960px; margin: auto; padding: 20px 0 40px; }
.welcome-copy h1 { font-size: clamp(44px,5.6vw,68px); line-height: 1.06; letter-spacing: -.055em; font-weight: 650; margin: 0 0 22px; }
.welcome-copy > p { max-width: 33ch; color: #716b65; font-size: 19px; line-height: 1.5; margin: 0 0 28px; }
.welcome-start { min-height: 50px; font-size: 16px; padding: 13px 24px; text-decoration: none; }
.welcome-note { display: block; margin-top: 12px; font-size: 12px; color: var(--ui-muted); }
.welcome-example { margin: 0; width: min(100%,340px); justify-self: center; }
.welcome-paper { padding: 10px; border: 1px solid var(--ui-line); border-radius: 26px; background: #fff; box-shadow: 0 14px 44px #58493610; }
.welcome-art { height: 285px; overflow: hidden; border-radius: 18px; }.welcome-art img { display: block; width: 100%; height: auto; }
.welcome-paper-copy { padding: 12px 12px 6px; }.welcome-paper-copy h2 { font-size: 22px; line-height: 1.2; font-weight: 600; margin: 0 0 8px; }.welcome-paper-copy p { font-size: 12px; color: var(--ui-muted); margin: 0; }
.welcome-gift { display: flex; justify-content: space-between; gap: 12px; margin-top: 18px; border-top: 1px solid var(--ui-line); padding-top: 14px; font-size: 13px; }.welcome-check { color: #ad5b45; }
.welcome-example figcaption { text-align: center; color: var(--ui-muted); font-size: 11px; margin-top: 14px; }
#authView .auth-card { max-width: 420px; margin: 6vh auto 0; padding: 30px; border: 1px solid var(--ui-line); background: #fff; border-radius: 24px; box-shadow: 0 10px 30px #51432d08; text-align: center; }
#authView h2 { font-size: 30px; line-height: 1.15; margin: 0 0 12px; font-weight: 650; letter-spacing: -.03em; }
#authView .auth-card > p { font-size: 15px; line-height: 1.5; margin: 0; }
#authView .auth-primary { display: flex; flex-direction: column; align-items: center; padding: 22px 0 0; margin: 0; border: 0; background: none; box-shadow: none; }
.auth-symbol { display: block; margin-bottom: 6px; }.auth-primary .hero-actions { justify-content: center; min-height: 44px; }
#authView .auth-primary p { margin: 16px 0 0; font-size: 12px; }
/* Editor: one surface, four clear steps, compact content with full-size touch targets. */
#editorView .editor-app-shell { width: min(100%,640px); padding: 0 0 calc(90px + var(--app-safe-bottom, env(safe-area-inset-bottom))); }
#editorView .editor-mini-head { position: static; grid-template-columns: 44px minmax(0,1fr) 44px; gap: 10px; margin: 0 0 14px; }
#editorView .mini-nav-button { width: 44px; height: 44px; border-radius: 14px; background: #fff; box-shadow: none; backdrop-filter: none; font-weight: 500; }
#editorView .editor-title-pill { padding: 3px 0; background: none; box-shadow: none; color: var(--text); text-align: center; }
#editorView .editor-title-pill span { font-size: 11px; color: var(--ui-muted); font-weight: 500; }#editorView .editor-title-pill b { font-size: 15px; font-weight: 600; }
#editorView .compact-editor-card { padding: 20px; border: 1px solid var(--ui-line); border-radius: 22px; background: var(--ui-paper); box-shadow: none; }
#editorView .mini-step-progress { padding: 0; margin-bottom: 8px; background: none; border: 0; box-shadow: none; }
#editorView .progress-meta, #editorView .progress-track { display: none; }
#editorView .compact-step-dots { gap: 4px; padding: 4px; border-radius: 14px; background: #f2f1ed; }
#editorView .editor-step-pill { min-height: 44px; border: 0; border-radius: 10px; background: transparent; box-shadow: none; padding: 8px 2px; gap: 3px; }
#editorView .editor-step-pill b { font-size: 12px; font-weight: 600; }#editorView .editor-step-pill small { font-size: 9px; font-weight: 400; }
#editorView .editor-step-pill.active { background: #fff; color: var(--text); box-shadow: 0 1px 4px #30271814; }#editorView .editor-step-pill.active small { color: var(--ui-muted); }
#editorView .editor-step-pill.done { color: var(--primary-hover); background: none; }
#editorView .guest-owner-nav { display: flex; justify-content: flex-end; margin: 2px 0 8px; }#editorView .guest-owner-nav .btn { min-height: 36px; font-size: 12px; border: 0; background: none; padding: 6px 0 6px 12px; }
#editorView .editor-section-title { font-size: 23px; line-height: 1.2; letter-spacing: -.03em; font-weight: 650; margin: 0 0 4px; }
#editorView .style-flow { gap: 16px; }#editorView .style-step-panel { padding: 0; background: none; box-shadow: none; border: 0; border-radius: 0; scroll-margin-top: 16px; }
#editorView .control-label { font-size: 13px; font-weight: 600; margin: 0 0 8px; }
.color-options { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 8px; }
.color-option { min-width: 0; display: flex; align-items: center; flex-direction: column; gap: 5px; padding: 7px 3px; border: 1px solid transparent; border-radius: 14px; background: #f7f6f2; color: #645f58; font-size: 11px; cursor: pointer; }
.color-option img { border-radius: 50%; width: 36px; height: 36px; }.color-option.is-selected { border-color: var(--primary); background: var(--primary-soft); color: var(--text); }
#editorView .mode-switch { margin: 0; width: 100%; max-width: none; min-height: 44px; padding: 3px; border: 0; border-radius: 12px; background: #f2f1ed; box-shadow: none; }#editorView .mode-switch::before { display: none; }
#editorView .mode-choice { min-height: 40px; border: 0; border-radius: 9px; padding: 8px; font-size: 14px; background: none; box-shadow: none; color: var(--ui-muted); }#editorView .mode-choice.active { background: #fff; color: var(--text); box-shadow: 0 1px 4px #30271812; }
#editorView .template-carousel-shell { gap: 0; }#editorView .template-carousel { min-height: 290px; height: 290px; perspective: none; }
#editorView .template-slide { width: 195px; transition: opacity .18s, transform .18s; animation: none; }
#editorView .template-slide.is-active { transform: none; }#editorView .template-slide.is-left { transform: translateX(-77%) scale(.82); opacity: .3; }#editorView .template-slide.is-right { transform: translateX(77%) scale(.82); opacity: .3; }
#editorView .template-preview-card { padding: 5px; border-radius: 18px; box-shadow: 0 6px 20px #58493612; }#editorView .template-preview-card img { border-radius: 13px; }
#editorView .carousel-arrow { width: 44px; height: 44px; background: #fff; border: 1px solid var(--ui-line); box-shadow: 0 2px 8px #3027180a; }#editorView .template-caption { margin: 0 0 10px; font-size: 13px; color: var(--text); }#editorView .template-caption span { margin-left: 8px; font-size: 11px; color: var(--ui-muted); }
#editorView .style-done { width: 100%; min-height: 46px; }
#editorView .form-grid { gap: 0; align-items: start; }#editorView .form-section { padding: 16px 0; margin: 0; gap: 12px; align-content: start; background: none; border: 0; border-bottom: 1px solid var(--ui-line); border-radius: 0; box-shadow: none; }#editorView .form-section:first-child { padding-top: 0; }#editorView .form-section:last-child { border-bottom: 0; padding-bottom: 0; }
#editorView .form-section h3 { font-size: 18px; font-weight: 600; margin: 0; }
#editorView label { font-size: 13px; line-height: 1.35; gap: 6px; align-content: start; min-width: 0; }
#editorView input, #editorView textarea, #editorView select { width: 100%; min-width: 0; min-height: 44px; padding: 10px 12px; border: 1px solid #dedbd5; border-radius: 11px; background: #fff; color: #38342f; font-size: 16px; line-height: 1.4; box-shadow: none; }
#editorView textarea { min-height: 72px; max-height: 240px; resize: vertical; }#editorView .date-time-row { gap: 12px; }
#editorView .cover-upload { display: grid; grid-template-columns: 112px minmax(0,1fr); gap: 16px; padding: 0; margin: 0 0 4px; border: 0; border-radius: 0; background: none; align-items: center; }
#editorView .template-art-preview { width: 112px; max-width: 112px; border-radius: 12px; box-shadow: 0 2px 8px #3027180a; }#editorView .cover-actions { display: flex; flex-direction: column; align-items: stretch; gap: 8px; }.cover-label-copy { margin: 0; font-size: 12px; color: var(--ui-muted); }
#editorView .cover-actions .btn { width: 100%; min-height: 44px; font-size: 13px; padding: 8px 10px; }#editorView .file-input { display: none; }#editorView .template-art-photo small { display: none; }#editorView .template-art-photo .photo-camera-icon { width: 18px; height: 14px; }
#editorView .template-box { display: block; padding: 0; margin: -2px 0 2px; border: 0; background: none; box-shadow: none; border-radius: 0; }#editorView .template-box summary { width: fit-content; min-height: 32px; padding: 6px 0; cursor: pointer; font-size: 12px; color: var(--primary-hover); }#editorView .template-options { display: flex; flex-wrap: wrap; margin: 4px 0 8px; gap: 6px; }
#editorView .editor-sticky-bar { width: min(640px,calc(100vw - 24px)); border-radius: 18px; padding: 6px; background: #fffefdf2; box-shadow: 0 4px 20px #30271812; bottom: calc(8px + var(--app-safe-bottom, env(safe-area-inset-bottom))); backdrop-filter: blur(12px); }
#editorView .editor-sticky-bar .btn { min-height: 44px; font-size: 14px; border-radius: 12px; }
#editorView .gifts-step-head { background: none; border: 0; padding: 0 0 16px; gap: 12px; }#editorView .gifts-step-head p { font-size: 13px; margin: 0; }
#editorView .gift-form { padding: 16px; box-shadow: none; border: 1px solid var(--ui-line); border-radius: 16px; background: #faf9f6; }#editorView .gift-form .form-grid { gap: 12px; }
#editorView .gift-admin-card { box-shadow: none; border: 1px solid var(--ui-line); border-radius: 16px; padding: 14px; gap: 12px; }.share-panel { box-shadow: none; border-radius: 18px; padding: 18px; }
#dashboardView .page-head, #dashboardView .dashboard-grid { width: min(100%,720px); margin-inline: auto; }
#dashboardView .page-head { padding: 4px 0 20px; gap: 12px; }#dashboardView .page-head p { font-size: 14px; margin: 6px 0 0; }
#dashboardView .dashboard-grid { grid-template-columns: 1fr; gap: 10px; }#dashboardView .event-item { grid-template-columns: 72px minmax(0,1fr); padding: 16px; gap: 16px; border: 1px solid var(--ui-line); border-radius: 18px; background: #fff; box-shadow: none; }
#dashboardView .event-preview { width: 72px; height: 96px; border-radius: 11px; }#dashboardView .event-item h3 { font-size: 18px; padding-right: 30px; line-height: 1.25; margin: 6px 0; }#dashboardView .event-item p { font-size: 12px; line-height: 1.4; margin: 4px 0 8px; }#dashboardView .event-chips { gap: 6px; }#dashboardView .event-chips .tag { font-size: 11px; padding: 4px 8px; }
:is(#publicView,.invitation-preview) .guest-quick { gap: 8px; margin-bottom: 14px; }:is(#publicView,.invitation-preview) .guest-quick .btn { padding: 10px 12px; min-height: 44px; font-size: 13px; }
:is(#publicView,.invitation-preview) .guest-side { padding: 10px; border-radius: 24px; box-shadow: none; }.invitation-card { gap: 10px; }.glass-block { box-shadow: none; border-radius: 18px; padding: 16px; }.invitation-title h2 { font-size: clamp(25px,5vw,34px); line-height: 1.15; }.decor-line { display: none; }.message-card p { margin: 0; font-size: 15px; line-height: 1.5; white-space: pre-line; }.wishlist-glass { display: none; }
:is(#publicView,.invitation-preview) .wishlist-intro { padding: 18px; border-radius: 18px; box-shadow: none; }:is(#publicView,.invitation-preview) .wishlist-intro h3 { font-size: 22px; }:is(#publicView,.invitation-preview) .wishlist-intro p { font-size: 14px; line-height: 1.5; }.guest-response { padding: 20px; border-radius: 18px; background: #fff; box-shadow: none; }.guest-response h3 { font-size: 24px; }.guest-response form { gap: 12px; }.guest-response input,.guest-response textarea,.guest-response select { min-height: 44px; padding: 10px 12px; border-radius: 11px; }.guest-response textarea { min-height: 72px; }
.modal-card, .guest-receipt { border-radius: 22px; padding: 24px; box-shadow: 0 12px 50px #30271824; }.footer { font-size: 11px; color: #878078; margin-top: 22px; }
@media(max-width:700px) {
  .shell { padding: calc(12px + var(--app-safe-top, env(safe-area-inset-top))) 16px 20px; }.topbar { margin-bottom: 12px; min-height: 48px; }.brand { font-size: 20px; }.topbar .top-actions .btn { font-size: 12px; padding: 8px 12px; }
  .welcome-layout { display: flex; flex-direction: column; gap: 24px; min-height: 0; padding: 12px 0 4px; }.welcome-copy { text-align: center; }.welcome-copy h1 { font-size: 42px; margin-bottom: 14px; }.welcome-copy > p { font-size: 15px; margin: 0 auto 20px; max-width: 32ch; }.welcome-start { width: 100%; max-width: 330px; min-height: 48px; }.welcome-note { margin-top: 9px; font-size: 11px; }
  .welcome-example { width: 244px; }.welcome-paper { border-radius: 20px; padding: 7px; }.welcome-art { height: 188px; border-radius: 14px; }.welcome-paper-copy { padding: 8px; }.welcome-paper-copy h2 { font-size: 17px; }.welcome-paper-copy p { font-size: 10px; }.welcome-gift { margin-top: 10px; padding-top: 10px; font-size: 11px; }.welcome-example figcaption { margin-top: 10px; font-size: 10px; }
  #authView .auth-card { margin-top: 28px; padding: 28px 22px; }#authView h2 { font-size: 28px; }
  body.editor-mini-mode .shell { padding: calc(10px + var(--app-safe-top, env(safe-area-inset-top))) 12px 16px; }#editorView .compact-editor-card { padding: 14px; border-radius: 18px; }#editorView .editor-mini-head { margin-bottom: 10px; }#editorView .editor-section-title { font-size: 22px; }
  #editorView .template-carousel { min-height: 278px; height: 278px; }#editorView .template-slide { width: 184px; }#editorView .template-carousel-shell .carousel-arrow-left { left: 0; }#editorView .template-carousel-shell .carousel-arrow-right { right: 0; }
  #editorView .cover-upload { grid-template-columns: 102px minmax(0,1fr); gap: 12px; }#editorView .template-art-preview { width: 102px; max-width: 102px; }
  :is(#publicView,.invitation-preview) .guest-quick { display: grid; grid-template-columns: 1fr 1fr; }.guest-counts { grid-template-columns: 1fr 1fr; gap: 10px; }
  #dashboardView .event-item { padding: 14px; gap: 12px; }#dashboardView .event-item h3 { font-size: 16px; }
}
@media(prefers-reduced-motion:reduce) { *,*::before,*::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; } }
/* Route animation previously made fixed editor actions relative to a tall page. */
.view { animation: none; transform: none; }
#editorView input, #editorView textarea, #editorView select { font-weight: 450; }
#editorView label { font-weight: 550; }
#editorView .guest-owner-nav .btn, #editorView .template-box summary { min-height: 40px; }
.welcome-copy h1 { font-weight: 600; }
@media(max-width:700px) { .welcome-copy h1 { font-size: 40px; } }
.btn-accent { background: #c2533a; }.btn-accent:hover { background: #a9432e; }
body.theme-blue .btn-accent { background: #387bb3; }body.theme-beige .btn-accent { background: #766650; }body.theme-green .btn-accent { background: #ad5b45; }
#editorView .editor-app-shell[data-step="style"] { padding-bottom: 16px; }
#editorView .editor-app-shell[data-step="style"] .guest-owner-nav { display: none; }
#editorView .editor-app-shell[data-step="style"] .mini-step-progress { margin-bottom: 20px; }
.toast { bottom: calc(84px + var(--app-safe-bottom, env(safe-area-inset-bottom))); pointer-events: none; padding: 10px 16px; border: 1px solid var(--ui-line); box-shadow: 0 4px 20px #30271812; font-size: 13px; }

body.theme-blue .btn-accent:hover { background:#2e6594; } body.theme-beige .btn-accent:hover { background:#5b4e42; } body.theme-green .btn-accent:hover { background:#ad5b45; }

.wishlist-intro[hidden], .guest-quick .btn[hidden], .link-box[hidden] { display:none; }
.invitation-meta-grid { grid-template-columns: minmax(0,1fr) 100px; gap: 8px; }
.meta-card { min-height: 0; padding: 12px; gap: 8px; }.meta-card .theme-icon { width: 24px; height: 24px; flex: 0 0 24px; }.meta-card .theme-icon img { width: 24px; height: 24px; }
.meta-card b { font-size: 14px; line-height: 1.35; font-weight: 600; }.meta-card small { font-size: 11px; line-height: 1.4; }.meta-card.compact { gap: 6px; padding: 10px; }
.modal-card input, .modal-card textarea, .modal-card select { min-height: 44px; padding: 10px 12px; border-radius: 11px; font-size: 16px; font-weight: 450; }.modal-card textarea { min-height: 72px; }
#editorView .editor-app-shell[data-step="guests"] .guest-owner-nav { display: none; }
#editorView .editor-app-shell[data-step="guests"] { padding-bottom: 20px; }
.guest-totals { gap: 8px; margin: 14px 0; }.guest-totals > div { padding: 12px; border-radius: 14px; flex-basis: 110px; }.guest-totals b { font-size: 25px; }
@media(min-width:701px) { .welcome-copy h1 { font-size: clamp(44px,5vw,60px); } }
@media(max-width:350px) { #editorView .date-time-row { grid-template-columns: 1fr; } }

/* Crop gestures never scroll the document or drag the Telegram sheet. */
html.crop-page-locked, body.crop-page-locked { overscroll-behavior: none; overflow: hidden; }
#coverCropModal { touch-action: none; overscroll-behavior: none; padding: calc(12px + var(--app-safe-top, env(safe-area-inset-top))) 12px calc(12px + var(--app-safe-bottom, env(safe-area-inset-bottom))); }
#coverCropModal .crop-modal-card, #coverCropModal.crop-template-mode .modal-card.wide { max-height: 100%; overflow: hidden; padding: 16px; }
#coverCropModal .crop-modal-card > #cropHint { display: block; font-size: 13px; line-height: 1.4; margin: 4px 28px 8px 0; }
#coverCropModal .crop-stage { touch-action: none; overscroll-behavior: none; cursor: grab; -webkit-user-select: none; -webkit-touch-callout: none; min-height: 0; height: min(43dvh, 400px); }
#coverCropModal .crop-stage:active { cursor: grabbing; }
#coverCropModal .crop-stage img { -webkit-user-drag: none; user-select: none; }
#coverCropModal.crop-template-mode .crop-stage { width: min(72vw, 286px, calc((100dvh - var(--app-safe-top, env(safe-area-inset-top)) - var(--app-safe-bottom, env(safe-area-inset-bottom)) - 246px) * .75)); height: auto; margin: 10px auto; }
#coverCropModal .crop-tools { display: flex; justify-content: center; }
#coverCropModal .crop-tools .btn { min-height: 44px; padding: 8px 14px; }
#coverCropModal .hero-actions { display: flex; flex-wrap: nowrap; gap: 8px; margin-top: 10px !important; }
#coverCropModal .hero-actions .btn { flex: 1; padding: 10px 12px; min-height: 44px; }
#coverCropModal .crop-stage:focus-visible { outline: 3px solid var(--primary); outline-offset: 3px; }

/* Lighter form guidance; values retain normal type and native 16px input sizing. */
input::placeholder, textarea::placeholder { font-size:14px; font-weight:300; font-style:italic; color:#766f68; opacity:.5; }
.field-hint, .section-note, .cover-label-copy, .share-note { font-size:13px; font-style:italic; font-weight:300; line-height:1.45; color:#766f68; }
#editorView label { font-size:12px; font-weight:400; gap:4px; }
#editorView input, #editorView textarea, #editorView select { font-weight:400; padding:9px 11px; }
#editorView textarea { min-height:64px; }
#editorView .editor-section-title { font-size:21px; font-weight:500; }
#editorView .form-section { gap:10px; padding:14px 0; }
#editorView .form-section h3 { font-size:17px; font-weight:500; }
#editorView .btn, .modal-card .btn, .account-save .btn { font-size:13px; font-weight:500; padding:8px 12px; min-height:44px; }
#editorView .control-label, #editorView .editor-step-pill b { font-weight:500; }
#editorView .template-box summary { font-weight:400; }
#editorView .date-time-row { grid-template-columns:minmax(0,1.25fr) minmax(0,1fr); gap:0; border:1px solid #dedbd5; border-radius:11px; background:#fff; overflow:hidden; }
#editorView .date-time-row label { padding:7px 11px; gap:2px; }
#editorView .date-time-row label + label { border-left:1px solid #e8e5df; }
#editorView .date-time-row input { appearance:none; -webkit-appearance:none; display:block; width:100%; min-width:0; max-width:100%; height:28px; min-height:28px; padding:0; margin:0; border:0; border-radius:0; background:transparent; box-shadow:none; text-align:left; }
#editorView .date-time-row input:focus-visible { outline:none; }
#editorView .date-time-row:focus-within { outline:2px solid var(--primary); outline-offset:2px; }
#editorView .date-time-row input::-webkit-date-and-time-value { margin:0; padding:0; text-align:left; background:transparent; min-height:1.4em; }
#editorView .date-time-row input::-webkit-datetime-edit { padding:0; background:transparent; }
#editorView .date-time-row input::-webkit-calendar-picker-indicator { margin:0; padding:2px; opacity:.6; }
@media(max-width:350px) { #editorView .date-time-row label { padding-inline:8px; } }

#editorView .cover-upload { grid-template-columns:96px minmax(0,1fr); gap:12px; }
#editorView .template-art-preview { width:96px; max-width:96px; }
#editorView .cover-actions .btn { width:fit-content; max-width:100%; align-self:flex-start; }
