:root
{
    --background:
        #061425;

    --background-soft:
        #091a2d;

    --sidebar:
        #04101f;

    --panel:
        #0d2136;

    --panel-hover:
        #112943;

    --panel-light:
        #142d47;

    --border:
        #213b56;

    --border-light:
        #2c4a67;

    --text:
        #f5f8fb;

    --muted:
        #93a7ba;

    --muted-dark:
        #6e8398;

    --orange:
        #ff5e01;

    --orange-light:
        #ff7933;

    --danger:
        #ef5350;

    --radius:
        14px;

    --shadow:
        0 18px 45px rgba(0,0,0,.18);
}


*
{
    box-sizing:
        border-box;
}


html,
body
{
    margin:
        0;

    min-height:
        100%;

    background:
        var(--background);

    color:
        var(--text);

    font-family:
        Inter,
        Arial,
        Helvetica,
        sans-serif;
}


body
{
    min-height:
        100vh;
}


button,
input
{
    font:
        inherit;
}


button,
a
{
    -webkit-tap-highlight-color:
        transparent;
}


.hidden
{
    display:
        none !important;
}


/* =========================================================
   LOGIN
   ========================================================= */

.login-screen
{
    min-height:
        100vh;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    padding:
        40px;

    background:
        radial-gradient(
            circle at 20% 10%,
            #102c48 0,
            #07182a 38%,
            #04101e 100%
        );
}


.login-layout
{
    width:
        100%;

    max-width:
        1100px;

    display:
        grid;

    grid-template-columns:
        1.15fr .85fr;

    gap:
        80px;

    align-items:
        center;
}


.login-brand-area
{
    padding:
        20px;
}


.login-main-logo
{
    width:
        355px;

    max-width:
        90%;

    height:
        auto;

    display:
        block;

    margin-bottom:
        55px;
}


.eyebrow
{
    display:
        inline-block;

    color:
        var(--orange);

    font-size:
        12px;

    font-weight:
        800;

    letter-spacing:
        1.8px;

    margin-bottom:
        12px;
}


.login-intro h1
{
    margin:
        0;

    font-size:
        clamp(42px, 5vw, 68px);

    line-height:
        1;

    letter-spacing:
        -2px;
}


.login-intro p
{
    margin-top:
        20px;

    max-width:
        510px;

    color:
        var(--muted);

    font-size:
        18px;

    line-height:
        1.6;
}


.login-card
{
    background:
        rgba(13,33,54,.96);

    border:
        1px solid var(--border);

    border-radius:
        20px;

    padding:
        38px;

    box-shadow:
        var(--shadow);
}


.login-card-title h2
{
    margin:
        0;

    font-size:
        28px;
}


.login-card-title p
{
    margin:
        8px 0 28px;

    color:
        var(--muted);
}


.form-group
{
    margin-bottom:
        18px;
}


.form-group label
{
    display:
        block;

    margin-bottom:
        8px;

    color:
        #c7d2dc;

    font-size:
        13px;

    font-weight:
        700;
}


.form-group input
{
    width:
        100%;

    height:
        48px;

    padding:
        0 14px;

    color:
        white;

    background:
        #07182a;

    border:
        1px solid var(--border);

    border-radius:
        9px;

    outline:
        none;

    transition:
        .15s ease;
}


.form-group input:focus
{
    border-color:
        var(--orange);

    box-shadow:
        0 0 0 3px rgba(255,94,1,.13);
}


.button
{
    display:
        inline-flex;

    align-items:
        center;

    justify-content:
        center;

    gap:
        8px;

    min-height:
        44px;

    padding:
        0 18px;

    border-radius:
        8px;

    text-decoration:
        none;

    font-weight:
        800;

    font-size:
        14px;

    cursor:
        pointer;

    transition:
        .16s ease;
}


.button-primary
{
    color:
        white;

    background:
        var(--orange);

    border:
        1px solid var(--orange);
}


.button-primary:hover
{
    background:
        var(--orange-light);

    border-color:
        var(--orange-light);

    transform:
        translateY(-1px);
}


.button-full
{
    width:
        100%;

    margin-top:
        6px;
}


.button-outline
{
    color:
        white;

    background:
        transparent;

    border:
        1px solid var(--border-light);
}


.button-outline:disabled
{
    opacity:
        .45;

    cursor:
        not-allowed;
}


.message-error
{
    margin-top:
        18px;

    padding:
        12px 14px;

    color:
        #ffd1d1;

    background:
        rgba(180,40,40,.2);

    border:
        1px solid rgba(255,80,80,.3);

    border-radius:
        8px;

    font-size:
        13px;
}


.login-help
{
    margin-top:
        24px;

    padding-top:
        18px;

    border-top:
        1px solid var(--border);

    color:
        var(--muted-dark);

    text-align:
        center;

    font-size:
        12px;
}


/* =========================================================
   APP SHELL
   ========================================================= */

.app-shell
{
    min-height:
        100vh;

    display:
        grid;

    grid-template-columns:
        240px minmax(0,1fr);
}


.sidebar
{
    min-height:
        100vh;

    padding:
        22px 16px;

    display:
        flex;

    flex-direction:
        column;

    background:
        var(--sidebar);

    border-right:
        1px solid var(--border);
}


.sidebar-logo
{
    padding:
        7px 8px 30px;
}


.sidebar-logo img
{
    width:
        200px;

    max-width:
        100%;

    height:
        auto;

    display:
        block;
}


.main-navigation
{
    display:
        flex;

    flex-direction:
        column;

    gap:
        6px;
}


.nav-item
{
    width:
        100%;

    min-height:
        46px;

    padding:
        0 14px;

    display:
        flex;

    align-items:
        center;

    gap:
        12px;

    color:
        var(--muted);

    background:
        transparent;

    border:
        0;

    border-radius:
        8px;

    text-align:
        left;

    cursor:
        pointer;
}


.nav-item:hover
{
    color:
        white;

    background:
        rgba(255,255,255,.035);
}


.nav-item.active
{
    color:
        white;

    background:
        var(--panel-light);

    box-shadow:
        inset 3px 0 0 var(--orange);
}


.nav-icon
{
    width:
        22px;

    color:
        var(--orange);

    font-size:
        19px;

    text-align:
        center;
}


.sidebar-bottom
{
    margin-top:
        auto;

    padding:
        20px 10px 4px;

    border-top:
        1px solid var(--border);
}


.language-placeholder
{
    color:
        var(--muted-dark);

    font-size:
        11px;

    letter-spacing:
        .8px;
}


.language-placeholder span
{
    margin:
        0 5px;
}


/* =========================================================
   CONTENT
   ========================================================= */

.content-area
{
    min-width:
        0;
}


.topbar
{
    min-height:
        76px;

    padding:
        0 34px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        space-between;

    background:
        rgba(7,24,42,.88);

    border-bottom:
        1px solid var(--border);
}


.topbar-title h1
{
    margin:
        0;

    font-size:
        17px;

    font-weight:
        800;
}


.user-box
{
    display:
        flex;

    align-items:
        center;

    gap:
        11px;
}


.user-circle
{
    width:
        36px;

    height:
        36px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    color:
        white;

    background:
        var(--orange);

    border-radius:
        50%;

    font-size:
        13px;

    font-weight:
        900;
}


.user-meta
{
    display:
        flex;

    flex-direction:
        column;

    min-width:
        130px;
}


.user-meta strong
{
    font-size:
        12px;

    font-weight:
        800;
}


.user-meta span
{
    margin-top:
        2px;

    color:
        var(--muted-dark);

    font-size:
        10px;
}


.logout-button
{
    margin-left:
        8px;

    color:
        var(--muted);

    background:
        transparent;

    border:
        0;

    cursor:
        pointer;

    font-size:
        12px;
}


.logout-button:hover
{
    color:
        white;
}


.dashboard-content
{
    width:
        100%;

    max-width:
        1400px;

    margin:
        0 auto;

    padding:
        44px 44px 70px;
}


.welcome-section
{
    margin-bottom:
        26px;
}


.welcome-section h2
{
    margin:
        0;

    font-size:
        34px;

    letter-spacing:
        -.7px;
}


.welcome-section p
{
    margin:
        8px 0 0;

    color:
        var(--muted);
}


/* =========================================================
   PRIMARY CARDS
   ========================================================= */

.primary-actions
{
    display:
        grid;

    grid-template-columns:
        repeat(2,minmax(0,1fr));

    gap:
        18px;

    margin-bottom:
        20px;
}


.primary-card
{
    min-height:
        220px;

    padding:
        26px;

    display:
        flex;

    gap:
        24px;

    background:
        linear-gradient(
            145deg,
            var(--panel),
            #0a1d31
        );

    border:
        1px solid var(--border);

    border-radius:
        var(--radius);

    box-shadow:
        0 10px 30px rgba(0,0,0,.08);
}


.primary-card:hover
{
    border-color:
        var(--border-light);
}


.primary-card-icon
{
    flex:
        0 0 54px;

    width:
        54px;

    height:
        54px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    color:
        var(--orange);

    background:
        rgba(255,94,1,.09);

    border:
        1px solid rgba(255,94,1,.22);

    border-radius:
        11px;

    font-size:
        25px;

    font-weight:
        900;
}


.primary-card-content
{
    display:
        flex;

    flex-direction:
        column;

    align-items:
        flex-start;
}


.card-kicker,
.panel-kicker
{
    color:
        var(--orange);

    font-size:
        10px;

    font-weight:
        900;

    letter-spacing:
        1.6px;
}


.primary-card h3
{
    margin:
        7px 0 7px;

    font-size:
        22px;
}


.primary-card p
{
    max-width:
        400px;

    margin:
        0 0 21px;

    color:
        var(--muted);

    line-height:
        1.5;

    font-size:
        13px;
}


.primary-card .button
{
    margin-top:
        auto;
}


/* =========================================================
   PANELS
   ========================================================= */

.dashboard-panel
{
    margin-top:
        18px;

    padding:
        24px;

    background:
        var(--panel);

    border:
        1px solid var(--border);

    border-radius:
        var(--radius);
}


.panel-heading
{
    margin-bottom:
        18px;
}


.panel-heading h3
{
    margin:
        5px 0 0;

    font-size:
        18px;
}


.quicklink-grid
{
    display:
        grid;

    grid-template-columns:
        repeat(3,minmax(0,1fr));

    gap:
        12px;
}


.quicklink-card
{
    min-height:
        82px;

    padding:
        15px;

    display:
        flex;

    align-items:
        center;

    gap:
        13px;

    color:
        white;

    background:
        var(--background-soft);

    border:
        1px solid var(--border);

    border-radius:
        10px;

    text-decoration:
        none;

    transition:
        .15s ease;
}


.quicklink-card:hover
{
    background:
        var(--panel-hover);

    border-color:
        var(--orange);

    transform:
        translateY(-1px);
}


.quicklink-icon
{
    width:
        36px;

    height:
        36px;

    flex:
        0 0 36px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    color:
        var(--orange);

    background:
        rgba(255,94,1,.08);

    border-radius:
        8px;

    font-size:
        18px;

    font-weight:
        900;
}


.quicklink-card div
{
    min-width:
        0;
}


.quicklink-card strong
{
    display:
        block;

    font-size:
        13px;
}


.quicklink-card div span
{
    display:
        block;

    margin-top:
        4px;

    color:
        var(--muted);

    font-size:
        10px;
}


.empty-state
{
    min-height:
        150px;

    padding:
        25px;

    display:
        flex;

    flex-direction:
        column;

    align-items:
        center;

    justify-content:
        center;

    text-align:
        center;

    background:
        rgba(3,15,28,.3);

    border:
        1px dashed var(--border);

    border-radius:
        10px;
}


.empty-state-icon
{
    margin-bottom:
        10px;

    color:
        var(--orange);

    font-size:
        30px;
}


.empty-state strong
{
    font-size:
        13px;
}


.empty-state p
{
    max-width:
        420px;

    margin:
        7px 0 0;

    color:
        var(--muted);

    font-size:
        11px;

    line-height:
        1.5;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 1000px)
{
    .login-layout
    {
        grid-template-columns:
            1fr;

        gap:
            35px;

        max-width:
            600px;
    }


    .login-brand-area
    {
        padding:
            0;
    }


    .login-main-logo
    {
        width:
            280px;

        margin-bottom:
            30px;
    }


    .primary-actions
    {
        grid-template-columns:
            1fr;
    }


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


@media (max-width: 760px)
{
    .app-shell
    {
        display:
            block;
    }


    .sidebar
    {
        min-height:
            auto;

        padding:
            14px;

        border-right:
            0;

        border-bottom:
            1px solid var(--border);
    }


    .sidebar-logo
    {
        padding:
            3px 4px 15px;
    }


    .sidebar-logo img
    {
        width:
            185px;
    }


    .main-navigation
    {
        display:
            grid;

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


    .sidebar-bottom
    {
        display:
            none;
    }


    .topbar
    {
        padding:
            13px 18px;
    }


    .topbar-title
    {
        display:
            none;
    }


    .user-box
    {
        width:
            100%;

        justify-content:
            flex-end;
    }


    .dashboard-content
    {
        padding:
            28px 18px 50px;
    }


    .quicklink-grid
    {
        grid-template-columns:
            1fr;
    }
}


@media (max-width: 520px)
{
    .login-screen
    {
        padding:
            22px 15px;
    }


    .login-card
    {
        padding:
            25px 20px;
    }


    .login-intro h1
    {
        font-size:
            39px;
    }


    .main-navigation
    {
        grid-template-columns:
            1fr;
    }


    .primary-card
    {
        display:
            block;
    }


    .primary-card-icon
    {
        margin-bottom:
            18px;
    }
}


/* =========================================================
   NAVPLAN LIST
   ========================================================= */

.panel-heading-row
{
    display:
        flex;

    align-items:
        center;

    justify-content:
        space-between;

    gap:
        20px;
}


.navplan-list
{
    display:
        flex;

    flex-direction:
        column;

    gap:
        8px;
}


.navplan-row
{
    min-height:
        68px;

    padding:
        12px 15px;

    display:
        flex;

    align-items:
        center;

    gap:
        14px;

    background:
        var(--background-soft);

    border:
        1px solid var(--border);

    border-radius:
        9px;
}


.navplan-row:hover
{
    border-color:
        var(--border-light);

    background:
        var(--panel-hover);
}


.navplan-row-icon
{
    width:
        38px;

    height:
        38px;

    flex:
        0 0 38px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    color:
        var(--orange);

    background:
        rgba(255,94,1,.08);

    border-radius:
        8px;
}


.navplan-row-main
{
    flex:
        1;

    min-width:
        0;

    display:
        flex;

    flex-direction:
        column;
}


.navplan-row-main strong
{
    overflow:
        hidden;

    text-overflow:
        ellipsis;

    white-space:
        nowrap;

    font-size:
        13px;
}


.navplan-row-main span
{
    margin-top:
        5px;

    color:
        var(--muted);

    font-size:
        10px;
}


.navplan-open
{
    color:
        var(--orange);

    text-decoration:
        none;

    font-size:
        11px;

    font-weight:
        800;
}


.navplan-open:hover
{
    color:
        var(--orange-light);
}


@media (max-width: 650px)
{
    .panel-heading-row
    {
        align-items:
            flex-start;

        flex-direction:
            column;
    }


    .navplan-row
    {
        align-items:
            flex-start;
    }


    .navplan-row-action
    {
        display:
            none;
    }
}

/* Einheitliche Quicklink-Icons */
.quicklink-icon i {
    width: 22px;
    display: inline-block;
    text-align: center;
    font-size: 19px;
    line-height: 1;
}

/* Einheitliche Quicklink-Icons */
.quicklink-icon i {
    width: 22px;
    display: inline-block;
    text-align: center;
    font-size: 19px;
    line-height: 1;
}

/* Density Altitude – neutrales, unverzerrbares DA-Symbol */
.quicklink-icon.density-da-icon {
    font-family: Arial, Helvetica, sans-serif;
    font-size: 13px;
    font-weight: 900;
    letter-spacing: -0.4px;
    line-height: 36px;
    text-align: center;
    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;
    padding: 0;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    color: var(--orange);
}

/* =========================================================
   Meine Navigationspläne
   Maximal ca. 5 Einträge sichtbar
   ========================================================= */

#navplanList {
    max-height: 370px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 5px;
}

#navplanList::-webkit-scrollbar {
    width: 7px;
}

#navplanList::-webkit-scrollbar-track {
    background: transparent;
}

#navplanList::-webkit-scrollbar-thumb {
    background: #29445f;
    border-radius: 8px;
}

#navplanList::-webkit-scrollbar-thumb:hover {
    background: #3b5a77;
}


/* =========================================================
   EIGENE LINKS – SIDEBAR
   ========================================================= */

.custom-links-sidebar {
    margin-top: 22px;
    padding: 16px 5px 0;
    border-top: 1px solid var(--border);
}

.custom-links-title {
    margin: 0 9px 8px;
    color: var(--muted-dark);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.custom-sidebar-link {
    min-height: 40px;
    padding: 8px 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--muted);
    text-decoration: none;
    border-radius: 7px;
}

.custom-sidebar-link:hover {
    color: #fff;
    background: rgba(255,255,255,.04);
}

.custom-sidebar-icon {
    width: 20px;
    flex: 0 0 20px;
    color: var(--orange);
    text-align: center;
    font-size: 12px;
}

.custom-sidebar-text {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 12px;
}


/* =========================================================
   EINSTELLUNGEN
   ========================================================= */

.settings-page {
    width: 100%;
}

.settings-header {
    margin-bottom: 26px;
}

.settings-header h2 {
    margin: 0;
    font-size: 34px;
    letter-spacing: -.7px;
}

.settings-header p {
    margin: 8px 0 0;
    color: var(--muted);
}

.settings-card {
    padding: 25px;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.settings-card-heading {
    margin-bottom: 22px;
}

.settings-card-heading h3 {
    margin: 0;
    font-size: 19px;
}

.settings-card-heading p {
    margin: 7px 0 0;
    color: var(--muted);
    font-size: 12px;
}

.custom-link-form-row {
    padding: 18px 0;
    display: flex;
    align-items: flex-start;
    gap: 16px;
    border-top: 1px solid var(--border);
}

.custom-link-number {
    width: 32px;
    height: 32px;
    flex: 0 0 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--orange);
    background: rgba(255,94,1,.09);
    border-radius: 50%;
    font-size: 12px;
    font-weight: 900;
}

.custom-link-fields {
    flex: 1;
    display: grid;
    grid-template-columns:
        minmax(180px, .7fr)
        minmax(260px, 1.3fr);
    gap: 16px;
}

.custom-link-fields .form-group {
    margin: 0;
}

.custom-link-fields input {
    width: 100%;
}

.settings-actions {
    padding-top: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    border-top: 1px solid var(--border);
}

.settings-message {
    color: var(--muted);
    font-size: 12px;
}

.settings-message-success {
    color: #65c58f;
}

.settings-message-error {
    color: #ff8d8d;
}


@media (max-width: 760px) {

    .custom-link-fields {
        grid-template-columns: 1fr;
    }
}


/* =========================================================
   DYNAMISCHE EIGENE LINKS
   ========================================================= */

.custom-links-editor {
    display: flex;
    flex-direction: column;
}

.custom-links-add-row {
    padding: 18px 0;
    display: flex;
    align-items: center;
    gap: 14px;
    border-top: 1px solid var(--border);
}

.custom-links-counter {
    color: var(--muted);
    font-size: 11px;
}

.custom-link-remove {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    margin-top: 23px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d27b7b;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 7px;
    cursor: pointer;
}

.custom-link-remove:hover {
    color: #fff;
    background: rgba(180,50,50,.2);
    border-color: rgba(220,80,80,.5);
}


/* Bei vielen persönlichen Links nicht die ganze Sidebar verlängern */
#customLinksList {
    max-height: 360px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 3px;
}

#customLinksList::-webkit-scrollbar {
    width: 6px;
}

#customLinksList::-webkit-scrollbar-track {
    background: transparent;
}

#customLinksList::-webkit-scrollbar-thumb {
    background: #29445f;
    border-radius: 8px;
}


@media (max-width: 760px) {

    .custom-link-remove {
        margin-top: 0;
    }
}
