/* ── Design tokens ───────────────────────────────────────────── */
:root {
    --primary-green: #4CAF50;
    --light-green: #E8F5E9;
    --dark-green: #2E7D32;
    --accent-leaf: #81C784;
    --bg-color: #F9FCF9;
    --card-bg: rgba(255, 255, 255, 0.85);
    --text-color: #2c3e50;
    --text-muted: #7f8c8d;
    --danger-red: #e74c3c;
    --border-radius: 20px;
    --shadow-soft: 0 10px 25px rgba(0, 0, 0, 0.05);
    --font-main: 'Outfit', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    --transition-speed: 0.3s;
}

/* ── Dark mode overrides ─────────────────────────────────────── */
body.dark-mode {
    --bg-color: #1a1a1a;
    --card-bg: rgba(40, 40, 40, 0.9);
    --text-color: #ecf0f1;
    --text-muted: #bdc3c7;
    --light-green: #2c3e50;
}

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

/* Apply font only to real elements, NOT pseudo-elements.
   Pseudo-elements like ::before / ::after inherit from the parent,
   but explicitly setting font-family here breaks Font Awesome icons
   which rely on their own font-family in ::before. */
* {
    font-family: var(--font-main);
}

/* ── Base ────────────────────────────────────────────────────── */
body {
    background-color: var(--bg-color);
    background-image:
        radial-gradient(at 10% 10%, rgba(76, 175, 80, 0.1) 0px, transparent 50%),
        radial-gradient(at 90% 90%, rgba(129, 199, 132, 0.1) 0px, transparent 50%);
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background-color var(--transition-speed), color var(--transition-speed);
}

/* ── App container ───────────────────────────────────────────── */
#app {
    width: 100%;
    max-width: 480px;
    height: 100vh;
    max-height: 900px;
    background: transparent;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* ── Views ───────────────────────────────────────────────────── */
.view {
    flex: 1;
    display: none;
    flex-direction: column;
    padding: 24px;
    padding-bottom: 120px;
    overflow-y: auto;
    animation: fadeIn 0.4s ease-out;
}

.view.active {
    display: flex;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ── Utilities ───────────────────────────────────────────────── */
.hidden {
    display: none !important;
}

.text-center {
    text-align: center;
}