*,
*::before,
*::after {
    box-sizing: border-box;
}

:root {
    --bg: #f4f7fb;
    --card: #ffffff;
    --line: #d9e2ec;
    --text: #4e6c84;
    --muted: #5c7289;
    --accent: #87bbe5;
    --accent-soft: #eaf1ff;
    --shadow: 0 18px 50px rgba(14, 30, 64, 0.08);
    --radius-xl: 28px;
    --radius-lg: 18px;
    --radius-md: 14px;
    --max-width: 840px;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background:
        radial-gradient(circle at top left, rgba(47, 111, 237, 0.07), transparent 35%),
        radial-gradient(circle at top right, rgba(30, 167, 253, 0.06), transparent 25%),
        var(--bg);
    color: var(--text);
    min-height: 100vh;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: inherit;
}

.shell {
    width: min(calc(100% - 32px), var(--max-width));
    margin: 0 auto;
    padding: 24px 0 48px;
}

.card {
    background: var(--card);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
    border: 1px solid rgba(217, 226, 236, 0.8);
}

.hero-card {
    padding: 24px;
    margin-bottom: 20px;
}

.eyebrow {
    margin: 0 0 8px;
    color: var(--accent);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-size: 0.8rem;
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1 {
    font-size: clamp(2rem, 4vw, 2.8rem);
    line-height: 1.08;
    margin-bottom: 12px;
}

h2 {
    font-size: clamp(1.35rem, 2.4vw, 1.9rem);
    margin-bottom: 12px;
}

.lead {
    color: var(--muted);
    font-size: 1rem;
    line-height: 1.65;
    max-width: 50ch;
    margin-bottom: 0;
}

.language-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin-top: 24px;
}

.language-button,
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 52px;
    padding: 14px 18px;
    border-radius: 999px;
    border: 1px solid transparent;
    background: var(--accent);
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
    cursor: pointer;
    box-shadow: 0 12px 28px rgba(47, 111, 237, 0.22);
}

.language-button:hover,
.button:hover {
    transform: translateY(-1px);
}

.language-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 24px;
    flex-wrap: wrap;
}

.back-link {
    text-decoration: none;
    font-weight: 600;
    color: var(--accent);
}

.language-chip {
    background: var(--accent-soft);
    color: var(--accent);
    padding: 8px 14px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.92rem;
}

.content-card {
    padding: 24px;
}

.content-header {
    margin-bottom: 20px;
}

.intro,
.footer-main,
.rich-text {
    color: var(--muted);
    line-height: 1.75;
    white-space: normal;
}

.accordion-stack {
    display: grid;
    gap: 14px;
}

.accordion-item {
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: #fff;
    overflow: hidden;
}

.accordion-item summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 20px;
    font-weight: 700;
    font-size: 1rem;
}

.accordion-item summary::-webkit-details-marker {
    display: none;
}

.accordion-icon {
    width: 14px;
    height: 14px;
    border-right: 2px solid var(--accent);
    border-bottom: 2px solid var(--accent);
    transform: rotate(45deg);
    transition: transform 0.2s ease;
    flex: 0 0 auto;
    margin-right: 2px;
}

.accordion-item[open] > summary .accordion-icon {
    transform: rotate(-135deg);
}

.accordion-content {
    padding: 0 20px 20px;
}

.accordion-children {
    display: grid;
    gap: 12px;
    margin-top: 16px;
}

.accordion-level-1,
.accordion-level-2,
.accordion-level-3,
.accordion-level-4 {
    background: #fbfcfe;
}

.accordion-level-1 {
    margin-left: 4px;
}

.accordion-level-2 {
    margin-left: 8px;
}

.accordion-level-3,
.accordion-level-4 {
    margin-left: 12px;
}

.section-image {
    margin: 16px 0 0;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--line);
    background: #f8fafc;
}

.page-footer {
    margin-top: 28px;
    padding-top: 20px;
    border-top: 1px solid var(--line);
}

.footer-note {
    margin: 14px 0 0;
    color: var(--text);
    font-weight: 600;
}

.phone-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 52px;
    padding: 14px 18px;
    margin: 0 0 8px;
    border-radius: 999px;
    border: 1px solid transparent;
    background: var(--accent);
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    text-align: center;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
    cursor: pointer;
    box-shadow: 0 12px 28px rgba(47, 111, 237, 0.22);
}

.phone-button:hover {
    transform: translateY(-1px);
}

.rich-text p + .phone-button,
.rich-text .phone-button + .phone-button {
    margin-top: 12px;
}

@media (min-width: 620px) {
    .hero-card,
    .content-card {
        padding: 32px;
    }

    .language-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 860px) {
    .shell {
        padding: 42px 0 60px;
    }

    .hero-card {
        display: grid;
        grid-template-columns: 1.5fr 1fr;
        gap: 24px;
        align-items: center;
    }

    .page-home .hero-card {
        align-items: end;
    }

    .page-content .hero-card {
        grid-template-columns: 1.6fr 0.8fr;
    }
}

/* Admin */
.admin-shell {
    width: min(calc(100% - 28px), 1180px);
}

.admin-grid {
    display: grid;
    gap: 18px;
}

.admin-card {
    padding: 20px;
    border-radius: 22px;
}

.admin-toolbar {
    display: flex;
    gap: 12px;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 18px;
}

.muted {
    color: var(--muted);
}

.lang-tabs,
.inline-actions,
.section-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.lang-tab,
.secondary-button,
.ghost-button,
.danger-button,
.small-button {
    border: 1px solid var(--line);
    background: #fff;
    color: var(--text);
    border-radius: 999px;
    padding: 10px 14px;
    font: inherit;
    cursor: pointer;
}

.lang-tab.active {
    background: var(--accent-soft);
    color: var(--accent);
    border-color: rgba(47, 111, 237, 0.22);
    font-weight: 700;
}

.secondary-button {
    background: var(--accent-soft);
    color: var(--accent);
    border-color: rgba(47, 111, 237, 0.15);
}

.ghost-button {
    background: #f8fafc;
}

.danger-button {
    color: #a22020;
    border-color: rgba(162, 32, 32, 0.18);
    background: #fff7f7;
}

.small-button {
    padding: 8px 12px;
    font-size: 0.92rem;
}

.form-grid {
    display: grid;
    gap: 14px;
}

.field {
    display: grid;
    gap: 6px;
}

.field label {
    font-weight: 700;
    font-size: 0.92rem;
}

.field input[type="text"],
.field textarea,
.field select {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 12px 14px;
    font: inherit;
    color: var(--text);
    background: #fff;
}

.field textarea {
    min-height: 110px;
    resize: vertical;
}

.field input[type="checkbox"] {
    transform: translateY(1px);
}

.section-tree {
    display: grid;
    gap: 12px;
    margin-top: 14px;
}

.section-editor {
    border: 1px solid var(--line);
    background: #fbfcfe;
    border-radius: 18px;
    padding: 16px;
}

.section-editor.level-1 { margin-left: 16px; }
.section-editor.level-2 { margin-left: 32px; }
.section-editor.level-3 { margin-left: 48px; }

.section-header {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.section-title {
    font-weight: 800;
}

.image-preview {
    width: 100%;
    max-width: 220px;
    border-radius: 14px;
    border: 1px solid var(--line);
    margin-top: 10px;
}

.status-box {
    padding: 14px 16px;
    border-radius: 16px;
    font-weight: 600;
    display: none;
}

.status-box.success {
    display: block;
    background: #eefaf2;
    color: #166534;
    border: 1px solid #c5e8cf;
}

.status-box.error {
    display: block;
    background: #fff3f3;
    color: #991b1b;
    border: 1px solid #f0c7c7;
}

@media (max-width: 720px) {
    .section-editor.level-1,
    .section-editor.level-2,
    .section-editor.level-3 {
        margin-left: 0;
    }
}


.language-list {
    display: grid;
    gap: 12px;
}

.language-row {
    border: 1px solid var(--line);
    background: #fbfcfe;
    border-radius: 18px;
    padding: 14px;
    display: grid;
    gap: 12px;
}

.language-row-grid {
    display: grid;
    gap: 12px;
}

.multi-field {
    gap: 10px;
}

.multi-stack {
    display: grid;
    gap: 10px;
}

.lang-field {
    display: grid;
    gap: 8px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #fbfcfe;
}

.lang-badge {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 6px 10px;
    border-radius: 999px;
    background: var(--accent-soft);
    color: var(--accent);
    font-size: 0.88rem;
    font-weight: 700;
}

.lang-field input[type="text"],
.lang-field textarea {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 12px 14px;
    font: inherit;
    color: var(--text);
    background: #fff;
}

.field-hint {
    margin: 2px 0 0;
    color: var(--muted);
    font-size: 0.9rem;
}

@media (min-width: 760px) {
    .language-row-grid {
        grid-template-columns: 1.2fr 0.9fr auto;
        align-items: end;
    }
}


.site-logo-wrap {
    display: flex;
    justify-content: center;
    margin: 8px 0 18px;
}

.site-logo {
    max-height: 92px;
    width: auto;
    max-width: min(72vw, 320px);
    object-fit: contain;
}

.admin-page {
    padding-bottom: 120px;
}

.admin-main-card {
    margin-bottom: 18px;
}

.admin-accordion-stack {
    display: grid;
    gap: 14px;
}

.admin-panel {
    border: 1px solid var(--line);
    border-radius: 20px;
    background: #fbfcfe;
    overflow: hidden;
}

.admin-panel > summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 20px;
}

.admin-panel > summary::-webkit-details-marker,
.section-editor > summary::-webkit-details-marker {
    display: none;
}

.admin-panel > summary strong,
.section-summary .section-title {
    display: block;
}

.admin-panel > summary small,
.section-meta {
    display: block;
    margin-top: 4px;
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 500;
}

.admin-panel-content {
    padding: 0 20px 20px;
}

.section-editor {
    overflow: hidden;
    padding: 0;
}

.section-summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 18px;
}

.section-body {
    padding: 0 16px 16px;
}

.save-dock {
    position: fixed;
    left: 50%;
    bottom: 16px;
    transform: translateX(-50%);
    width: min(calc(100% - 24px), 1040px);
    background: rgba(23, 50, 77, 0.96);
    color: #fff;
    border-radius: 22px;
    box-shadow: 0 20px 44px rgba(14, 30, 64, 0.22);
    padding: 14px 16px;
    display: flex;
    gap: 14px;
    align-items: center;
    justify-content: space-between;
    z-index: 30;
}

.save-dock .secondary-button,
.save-dock .ghost-button {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.15);
}

.save-dock .button {
    box-shadow: none;
}

.save-dock-copy {
    display: grid;
    gap: 4px;
}

.save-dock-copy span {
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.94rem;
}

.save-dock.has-unsaved {
    background: rgba(26, 44, 93, 0.98);
}

.save-dock.is-saving {
    opacity: 0.92;
}

.save-dock button:disabled {
    opacity: 0.7;
    cursor: wait;
}

.confirm-overlay {
    position: fixed;
    inset: 0;
    background: rgba(9, 18, 35, 0.45);
    display: grid;
    place-items: center;
    padding: 16px;
    z-index: 40;
}

.confirm-overlay[hidden] {
    display: none !important;
}

.confirm-dialog {
    width: min(100%, 520px);
    background: #fff;
    border-radius: 24px;
    padding: 24px;
    box-shadow: 0 24px 60px rgba(14, 30, 64, 0.24);
}

.confirm-dialog p {
    color: var(--muted);
    line-height: 1.65;
}

@media (max-width: 860px) {
    .save-dock {
        flex-direction: column;
        align-items: stretch;
    }

    .save-dock .inline-actions {
        width: 100%;
    }

    .save-dock .inline-actions > * {
        flex: 1 1 auto;
    }
}
.lysiteleia {text-align:center; font-size:9px; margin:0 auto 10px;}