/* ---------- undo.systems --- neomorphism soft ui ---------- */

:root {
    --surface: #E0E5EC;
    --shadow-light: #FFFFFF;
    --shadow-dark: #B8BEC7;
    --ink: #2D3436;
    --slate: #4A5568;
    --violet: #6C5CE7;
    --violet-soft: #A29BFE;
    --teal: #00CEC9;

    --shadow-extruded: 8px 8px 16px var(--shadow-dark), -8px -8px 16px var(--shadow-light);
    --shadow-extruded-sm: 5px 5px 10px var(--shadow-dark), -5px -5px 10px var(--shadow-light);
    --shadow-extruded-xs: 3px 3px 6px var(--shadow-dark), -3px -3px 6px var(--shadow-light);
    --shadow-pressed: inset 8px 8px 16px var(--shadow-dark), inset -8px -8px 16px var(--shadow-light);
    --shadow-pressed-sm: inset 5px 5px 10px var(--shadow-dark), inset -5px -5px 10px var(--shadow-light);
    --shadow-pressed-xs: inset 3px 3px 6px var(--shadow-dark), inset -3px -3px 6px var(--shadow-light);
    --shadow-flush: 0 0 0 var(--shadow-dark), 0 0 0 var(--shadow-light);
}

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

html, body {
    background: var(--surface);
    color: var(--slate);
    font-family: 'Quicksand', 'Nunito', system-ui, sans-serif;
    font-weight: 400;
    line-height: 1.7;
    font-size: 16px;
    min-height: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

.surface {
    min-height: 100vh;
    width: 100%;
    padding: 56px 48px 96px;
    position: relative;
}

/* ---------- Hero ---------- */

.hero {
    max-width: 1200px;
    margin: 0 auto;
}

.nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px;
    padding: 14px;
    border-radius: 36px;
    background: var(--surface);
    box-shadow: var(--shadow-extruded-sm);
    margin: 0 auto 80px;
    width: fit-content;
    max-width: 100%;
}

.nav-pill {
    border: 0;
    background: var(--surface);
    color: var(--slate);
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 12px 22px;
    border-radius: 24px;
    cursor: pointer;
    transition: box-shadow 250ms ease-out, color 250ms ease-out, transform 150ms ease-out;
    box-shadow: var(--shadow-extruded-xs);
}

.nav-pill:hover {
    color: var(--violet);
}

.nav-pill.active {
    box-shadow: var(--shadow-pressed-xs);
    color: var(--violet);
}

.hero-inner {
    text-align: center;
    padding: 64px 24px 96px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 28px;
}

.hero-emblem {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    background: var(--surface);
    box-shadow: var(--shadow-extruded);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    transition: box-shadow 400ms ease-out, transform 400ms ease-out;
}

.hero-emblem:hover {
    box-shadow: var(--shadow-pressed);
}

.undo-glyph {
    transform: rotate(0deg);
    transition: transform 600ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.hero-emblem:hover .undo-glyph {
    transform: rotate(-360deg);
}

.hero-title {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: clamp(40px, 6vw, 64px);
    color: var(--ink);
    letter-spacing: 0.01em;
    line-height: 1.1;
}

.hero-subtitle {
    font-family: 'Quicksand', sans-serif;
    font-weight: 400;
    font-size: 18px;
    color: var(--slate);
    max-width: 540px;
    line-height: 1.7;
}

.hero-controls {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: center;
    gap: 36px;
    margin-top: 20px;
}

/* ---------- Big Button ---------- */

.big-button {
    border: 0;
    background: var(--surface);
    color: var(--ink);
    border-radius: 50px;
    padding: 4px;
    cursor: pointer;
    box-shadow: var(--shadow-extruded);
    transition: box-shadow 250ms ease-out, transform 150ms ease-out;
    font-family: 'Nunito', sans-serif;
}

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

.big-button:active,
.big-button.pressed {
    box-shadow: var(--shadow-pressed);
    transform: translateY(0);
}

.big-button-inner {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 18px 32px;
    border-radius: 46px;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--ink);
}

.big-button.compact .big-button-inner {
    padding: 14px 24px;
    font-size: 12px;
}

/* ---------- Toggle ---------- */

.hero-toggle {
    display: inline-flex;
    align-items: center;
    gap: 14px;
}

.toggle-label,
.control-label {
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 13px;
    color: var(--slate);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.toggle {
    position: relative;
    display: inline-block;
    width: 64px;
    height: 32px;
    border-radius: 18px;
    background: var(--surface);
    box-shadow: var(--shadow-pressed-xs);
    cursor: pointer;
    transition: background 350ms ease-out, box-shadow 350ms ease-out;
    flex-shrink: 0;
}

.toggle-thumb {
    position: absolute;
    top: 4px;
    left: 4px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--surface);
    box-shadow: var(--shadow-extruded-xs);
    transition: transform 350ms cubic-bezier(0.34, 1.56, 0.64, 1), background 250ms ease-out;
}

.toggle[data-on="true"] {
    background: var(--violet);
    box-shadow: inset 3px 3px 6px rgba(60, 50, 160, 0.45), inset -3px -3px 6px rgba(180, 170, 255, 0.55);
}

.toggle[data-on="true"] .toggle-thumb {
    transform: translateX(32px);
    background: #FFFFFF;
    box-shadow: 2px 2px 5px rgba(60, 50, 160, 0.35), -2px -2px 5px rgba(255, 255, 255, 0.85);
}

/* ---------- Section ---------- */

.section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 64px 0;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 48px;
}

.section-marker {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--surface);
    box-shadow: var(--shadow-pressed-xs);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.section-title {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: clamp(28px, 4vw, 40px);
    color: var(--ink);
    letter-spacing: 0.01em;
    text-transform: lowercase;
}

.divider-groove {
    flex: 1;
    height: 6px;
    border-radius: 3px;
    background: var(--surface);
    box-shadow: var(--shadow-pressed-xs);
}

.footer-groove {
    margin: 32px 0 24px;
}

/* ---------- Card grid ---------- */

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 32px;
}

.contact-grid {
    grid-template-columns: 2fr 1fr;
}

@media (max-width: 860px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }
}

.card {
    background: var(--surface);
    border-radius: 20px;
    padding: 32px;
    box-shadow: var(--shadow-extruded);
    transition: box-shadow 300ms ease-out, transform 300ms ease-out, opacity 500ms ease-out;
    display: flex;
    flex-direction: column;
    gap: 18px;
    cursor: pointer;
    opacity: 0;
    transform: translateY(12px);
}

.card.materialized {
    opacity: 1;
    transform: translateY(0);
}

.card.pressed {
    box-shadow: var(--shadow-pressed);
}

.card.wide {
    grid-column: span 2;
}

@media (max-width: 720px) {
    .card.wide {
        grid-column: span 1;
    }
}

.card-icon {
    height: 72px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.card-title {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: 24px;
    color: var(--ink);
    letter-spacing: 0.01em;
}

.card-body {
    font-family: 'Quicksand', sans-serif;
    color: var(--slate);
    font-size: 16px;
    line-height: 1.7;
    flex: 1;
}

.card-body em {
    color: var(--violet);
    font-style: normal;
    font-weight: 500;
}

.card-control {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-top: 6px;
}

.knob-row {
    gap: 18px;
}

/* ---------- Sphere accents ---------- */

.sphere {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #FFFFFF 0%, var(--violet-soft) 45%, var(--violet) 100%);
    box-shadow: 4px 4px 8px var(--shadow-dark), -2px -2px 6px var(--shadow-light);
    display: inline-block;
}

.sphere.sphere-teal {
    background: radial-gradient(circle at 30% 30%, #FFFFFF 0%, #7CECEA 45%, var(--teal) 100%);
}

.sphere.small {
    width: 24px;
    height: 24px;
}

.sphere.offset {
    margin-left: -8px;
}

/* ---------- Knob ---------- */

.knob {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #F5F7FA 0%, var(--surface) 60%, #C9CFD8 100%);
    box-shadow: var(--shadow-extruded-sm);
    position: relative;
    cursor: grab;
    flex-shrink: 0;
    transition: box-shadow 250ms ease-out;
}

.knob:active {
    cursor: grabbing;
}

.knob-indicator {
    position: absolute;
    top: 8px;
    left: 50%;
    width: 4px;
    height: 14px;
    border-radius: 2px;
    background: var(--violet);
    transform: translateX(-50%);
    transform-origin: 50% 24px;
    box-shadow: 0 0 4px rgba(108, 92, 231, 0.4);
}

.dial-bank {
    display: flex;
    gap: 28px;
    margin-top: 18px;
    flex-wrap: wrap;
}

/* ---------- Pill button ---------- */

.pill-button {
    border: 0;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 13px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    background: var(--surface);
    color: var(--ink);
    padding: 14px 24px;
    border-radius: 24px;
    cursor: pointer;
    box-shadow: var(--shadow-extruded-xs);
    transition: box-shadow 220ms ease-out, color 220ms ease-out;
}

.pill-button:hover {
    color: var(--violet);
}

.pill-button:active {
    box-shadow: var(--shadow-pressed-xs);
}

.pill-button.primary {
    color: var(--violet);
}

/* ---------- Switch stack ---------- */

.switch-stack {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-top: 4px;
}

.switch-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 10px 16px;
    border-radius: 18px;
    box-shadow: var(--shadow-pressed-xs);
}

/* ---------- Meta pill ---------- */

.meta-pill {
    display: inline-block;
    padding: 8px 14px;
    border-radius: 16px;
    font-family: 'Nunito', sans-serif;
    font-size: 12px;
    font-weight: 700;
    color: var(--violet);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    box-shadow: var(--shadow-pressed-xs);
}

/* ---------- Form ---------- */

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 6px;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.input {
    font-family: 'Quicksand', sans-serif;
    font-size: 15px;
    color: var(--ink);
    background: var(--surface);
    border: 0;
    outline: none;
    border-radius: 16px;
    padding: 14px 18px;
    box-shadow: var(--shadow-pressed-xs);
    transition: box-shadow 250ms ease-out;
    resize: none;
}

.input:focus {
    box-shadow: var(--shadow-pressed-sm);
}

.textarea {
    min-height: 120px;
    font-family: 'Quicksand', sans-serif;
    line-height: 1.6;
}

.form-row {
    display: flex;
    align-items: center;
    gap: 14px;
}

/* ---------- Channels ---------- */

.channel-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-top: 4px;
}

.channel-list li {
    display: flex;
    align-items: center;
    gap: 14px;
    font-family: 'Quicksand', sans-serif;
    font-size: 15px;
    color: var(--slate);
    padding: 12px 16px;
    border-radius: 16px;
    box-shadow: var(--shadow-pressed-xs);
}

.channel-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #FFFFFF 0%, var(--violet-soft) 50%, var(--violet) 100%);
    box-shadow: 2px 2px 4px var(--shadow-dark), -1px -1px 3px var(--shadow-light);
    flex-shrink: 0;
}

.channel-dot.teal {
    background: radial-gradient(circle at 30% 30%, #FFFFFF 0%, #7CECEA 50%, var(--teal) 100%);
}

/* ---------- Progress ring ---------- */

.progress-ring {
    position: fixed;
    top: 28px;
    right: 28px;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--surface);
    box-shadow: var(--shadow-extruded-xs);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
}

.progress-ring svg {
    transform: rotate(-90deg);
    position: absolute;
    inset: 0;
    margin: auto;
}

.progress-track {
    fill: none;
    stroke: var(--shadow-dark);
    stroke-width: 6;
    opacity: 0.4;
}

.progress-fill {
    fill: none;
    stroke: var(--violet);
    stroke-width: 6;
    stroke-linecap: round;
    stroke-dasharray: 163.36;
    stroke-dashoffset: 163.36;
    transition: stroke-dashoffset 120ms linear;
}

.progress-label {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: 11px;
    color: var(--violet);
    letter-spacing: 0.04em;
    z-index: 1;
}

/* ---------- Footer ---------- */

.footer {
    max-width: 1200px;
    margin: 80px auto 0;
}

.footer-text {
    text-align: center;
    font-family: 'Nunito', sans-serif;
    font-weight: 600;
    font-size: 13px;
    color: var(--slate);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

/* ---------- Responsive ---------- */

@media (max-width: 720px) {
    .surface { padding: 36px 20px 64px; }
    .nav { gap: 8px; padding: 10px; margin-bottom: 56px; }
    .nav-pill { padding: 10px 16px; font-size: 12px; }
    .card { padding: 24px; }
    .hero-inner { padding: 32px 8px 56px; }
    .progress-ring { top: 16px; right: 16px; width: 52px; height: 52px; }
    .progress-ring svg { width: 52px; height: 52px; }
}
