 * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        :root {
            --primary: #1a4731;
            --secondary: #2d6a4f;
            --accent: #40916c;
            --gold: #d4a373;
            --cream: #faf6f1;
            --dark: #1b4332;
            --background: #f8f9fa;
            --surface: rgba(250, 246, 241, 0.08);
            --text: rgba(250, 246, 241, 0.95);
        }

        body {
            font-family: -apple-system, system-ui, sans-serif;
            min-height: 100vh;
            background: linear-gradient(135deg, #1a4731, #1b4332);
            color: var(--text);
            display: flex;
            flex-direction: column;
            align-items: center;
            padding: 0.75rem;
            font-size: 15px;
            line-height: 1.5;
        }


        .lang-select {
            display: flex;
            justify-content: center;
            gap: 0.6rem;
            margin-bottom: 1rem;
            margin-top: 1rem;
        }

        .app {
            width: 100%;
            max-width: 350px;
            background: rgba(27, 67, 50, 0.4);
            backdrop-filter: blur(20px);
            border-radius: 1.5rem;
            padding: 1.25rem;
            box-shadow: 0 1rem 2rem rgba(0, 0, 0, 0.3),
                0 0.25rem 0.5rem rgba(0, 0, 0, 0.2);
            border: 1px solid rgba(64, 145, 108, 0.2);
        }

        h1 {
            font-size: 1.2rem;
            font-weight: 600;
            text-align: center;
            margin-bottom: 0.6rem;
            background: linear-gradient(90deg, #40916c, #2d6a4f);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            letter-spacing: -0.3px;
        }

        .subtitle {
            font-size: 0.85rem;
            opacity: 0.7;
            text-align: center;
            margin-top: 0.6rem;
        }

        .lang-btn {
            display: flex;
            align-items: center;
            gap: 0.4rem;
            padding: 0.4rem 0.8rem;
            border: 1px solid var(--accent);
            border-radius: 0.5rem;
            background: transparent;
            color: var(--text);
            font-size: 0.50rem;
            cursor: pointer;
            transition: 0.2s;
        }

        .lang-btn.active {
            background: var(--accent);
        }

        .time-input {
            background: var(--surface);
            border-radius: 1.1rem;
            padding: 0.9rem;
            margin-bottom: 0.9rem;
            border: 1px solid rgba(64, 145, 108, 0.1);
        }

        .label {
            font-size: 0.75rem;
            opacity: 0.7;
            letter-spacing: 1.5px;
            text-align: center;
            margin-bottom: 0.6rem;
        }

        .time-select {
            display: flex;
            gap: 0.4rem;
            justify-content: center;
            position: relative;
        }

        .time-select {
            direction: ltr;
        }

        .wheel {
            width: 50px;
            height: 90px;
            overflow: hidden;
            background: rgba(27, 67, 50, 0.3);
            border-radius: 0.55rem;
            position: relative;
            border: 1px solid rgba(64, 145, 108, 0.2);
        }

        .numbers {
            overflow-y: scroll;
            scroll-snap-type: y mandatory;
            height: 100%;
            -ms-overflow-style: none;
            scrollbar-width: none;
        }

        .numbers::-webkit-scrollbar {
            display: none;
        }

        .num {
            height: 30px;
            display: grid;
            place-items: center;
            font-size: 1rem;
            font-variant-numeric: tabular-nums;
            scroll-snap-align: center;
            color: rgba(250, 246, 241, 0.8);
        }

        .separator {
            align-self: center;
            opacity: 0.4;
            font-size: 1.2rem;
            font-weight: 200;
        }

        .select-line {
            position: absolute;
            left: 0;
            right: 0;
            top: 50%;
            transform: translateY(-50%);
            height: 30px;
            border: 1px solid var(--accent);
            border-left: 0;
            border-right: 0;
            background: rgba(64, 145, 108, 0.15);
            pointer-events: none;
        }

        button.calc-btn {
            width: 100%;
            padding: 0.75rem;
            border: none;
            border-radius: 0.8rem;
            background: linear-gradient(90deg, #2d6a4f, #1a4731);
            color: var(--cream);
            font-size: 0.9rem;
            font-weight: 500;
            margin: 0.6rem 0;
            box-shadow: 0 2px 4px rgba(26, 71, 49, 0.3);
            cursor: pointer;
            transition: all 0.3s ease;
        }

        button.calc-btn:hover {
            background: linear-gradient(90deg, #40916c, #2d6a4f);
            transform: translateY(-1px);
        }

        .results {
            display: none;
            background: var(--surface);
            border-radius: 0.8rem;
            padding: 0.6rem 0.8rem;
            margin-top: 0.8rem;
            border: 1px solid rgba(64, 145, 108, 0.1);
        }

        .result {
            display: flex;
            align-items: center;
            padding: 0.6rem 0;
            border-bottom: 1px solid rgba(250, 246, 241, 0.06);
            justify-content: space-between;
        }

        .result:last-child {
            border: none;
        }

        .result .label {
            text-align: left;
            order: 1;
        }

        .result .time {
            font-size: 1rem;
            color: var(--gold);
            font-variant-numeric: tabular-nums;
            font-weight: 500;
            order: 2;
        }

        /* Arabe : label à gauche, heure à droite */
        body[data-lang="ar"] .result .label {
            order: 2;
            text-align: right;
        }

        body[data-lang="ar"] .result .time {
            order: 1;
            text-align: left;
        }

        .home-button {
            position: fixed;
            bottom: 15px;
            right: 15px;
            width: 50px;
            height: 50px;
            border-radius: 50%;
            display: flex;
            justify-content: center;
            align-items: center;
            z-index: 1000;
            text-decoration: none;
            transition: all 0.3s ease;
            background: linear-gradient(145deg, #2d6a4f, #40916c);
            box-shadow: 5px 5px 10px rgba(26, 71, 49, 0.4),
                -5px -5px 10px rgba(64, 145, 108, 0.3);
            animation: pulse 2s infinite alternate;
        }

        @keyframes pulse {
            0% {
                transform: scale(1);
                box-shadow: 5px 5px 10px rgba(26, 71, 49, 0.4),
                    -5px -5px 10px rgba(64, 145, 108, 0.3);
            }

            100% {
                transform: scale(1.05);
                box-shadow: 7px 7px 14px rgba(26, 71, 49, 0.5),
                    -7px -7px 14px rgba(64, 145, 108, 0.4);
            }
        }

        .home-button:hover {
            transform: translateY(-3px);
            box-shadow: 7px 7px 14px rgba(26, 71, 49, 0.5),
                -7px -7px 14px rgba(64, 145, 108, 0.4);
        }

        .home-icon {
            width: 20px;
            height: 20px;
            background-color: var(--cream);
            -webkit-mask: url('data:image/svg+xml,<svg viewBox="0 0 24 24" fill="currentColor" xmlns="http://www.w3.org/2000/svg"><path d="M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8h5z"/></svg>') no-repeat center;
            mask: url('data:image/svg+xml,<svg viewBox="0 0 24 24" fill="currentColor" xmlns="http://www.w3.org/2000/svg"><path d="M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8h5z"/></svg>') no-repeat center;
            -webkit-mask-size: contain;
            mask-size: contain;
        }

        footer {
            background: transparent;
            color: rgba(250, 246, 241, 0.6);
            text-align: center;
            padding: 0.6rem;
            font-size: 0.7rem;
            margin-top: 2rem;
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            letter-spacing: 0.3px;
            font-weight: 300;
            border: none;
            box-shadow: none;
            opacity: 1;
        }