﻿:root {
    --top: 56px;
    --bottom: 70px;
    --border: #eaeaea;
    --text: #111;
    --muted: #777;
    --bg: #fff;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;
    background: #f6f6f6;
    color: var(--text);
}

.topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--top);
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    z-index: 10;
    display: flex;
    align-items: center;
    padding: 0 8px;
}

    /* 3-slot layout: left / title / right */
    .topbar .slot {
        width: 56px; /* keeps title centered even if right/left differ */
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .topbar .title {
        flex: 1;
        text-align: center;
        font-weight: 600;
        font-size: 20px; /* ~25% bigger (was default ~16px) */
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        padding: 0 8px;
    }

.icon-btn {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border: 0;
    background: transparent;
    color: var(--text);
    border-radius: 10px;
    cursor: pointer;
}

    .icon-btn:active {
        background: #f2f2f2;
    }

.logo {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: #fafafa;
    display: grid;
    place-items: center;
    font-size: 12px;
    color: var(--muted);
    user-select: none;
}

.content {
    padding: calc(var(--top) + 12px) 14px calc(var(--bottom) + 12px);
}

.footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--bottom);
    background: var(--bg);
    border-top: 1px solid var(--border);
    z-index: 10;
    padding-bottom: env(safe-area-inset-bottom);
    display: flex;
    justify-content: space-around;
    align-items: stretch;
}

/* wrapper lets us shift the icons up without moving the whole bar */
.footer-inner {
    flex: 1;
    display: flex;
    justify-content: space-around;
    align-items: center;
    transform: translateY(-10px); /* move icons ~10px higher */
}

.nav-item {
    position: relative;
    width: 56px;
    height: 56px;
    display: grid;
    place-items: center;
    color: var(--muted);
    text-decoration: none;
}

    .nav-item i {
        font-size: 20px;
    }

    .nav-item.active {
        color: var(--text);
    }

        /* short underline */
        .nav-item.active::after {
            content: "";
            position: absolute;
            bottom: 10px;
            width: 25px;
            height: 2px;
            border-radius: 999px;
            background: currentColor;
        }
