@tailwind base;
@tailwind components;
@tailwind utilities;

@layer base {
    :root {
        --dat-page: #25303c;
        --dat-page-deep: #1b242d;
        --dat-road: #19212a;
        --dat-grid: #4f5d6d;
        --dat-blue: #2b50d9;
        --dat-blue-deep: #2144c2;
        --dat-text: #2b3139;
        --dat-muted: #5b6470;
    }

    body.auth-shell {
        position: relative;
        min-height: 100vh;
        overflow: hidden;
        font-family: "Segoe UI", Roboto, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
        color: var(--dat-text);
        background: linear-gradient(180deg, #33404d 0%, #212a34 100%);
    }

    body.auth-shell::before {
        content: "";
        position: fixed;
        inset: 0;
        background:
            linear-gradient(rgba(75, 88, 102, 0.34) 1px, transparent 1px),
            linear-gradient(90deg, rgba(75, 88, 102, 0.34) 1px, transparent 1px),
            linear-gradient(12deg, transparent 0 44%, rgba(22, 29, 38, 0.9) 44.5% 45.6%, transparent 46.2% 100%),
            linear-gradient(104deg, transparent 0 58%, rgba(20, 27, 36, 0.85) 58.4% 59.6%, transparent 60.2% 100%),
            linear-gradient(176deg, transparent 0 24%, rgba(23, 30, 39, 0.72) 24.4% 25.3%, transparent 25.8% 100%),
            radial-gradient(circle at 13% 58%, transparent 0 96px, rgba(18, 24, 32, 0.62) 98px 111px, transparent 113px),
            radial-gradient(circle at 84% 78%, transparent 0 122px, rgba(18, 24, 32, 0.58) 125px 140px, transparent 143px);
        background-size:
            42px 42px,
            42px 42px,
            100% 100%,
            100% 100%,
            100% 100%,
            100% 100%,
            100% 100%;
        opacity: 0.95;
        pointer-events: none;
    }

    body.auth-shell::after {
        content: "";
        position: fixed;
        inset: 0;
        background:
            linear-gradient(90deg, transparent 0 6%, rgba(18, 24, 32, 0.64) 6.2% 6.9%, transparent 7.2% 100%),
            linear-gradient(90deg, transparent 0 28%, rgba(18, 24, 32, 0.54) 28.2% 28.8%, transparent 29.1% 100%),
            linear-gradient(90deg, transparent 0 57%, rgba(18, 24, 32, 0.58) 57.1% 57.8%, transparent 58.1% 100%),
            linear-gradient(90deg, transparent 0 73%, rgba(18, 24, 32, 0.52) 73.2% 73.9%, transparent 74.2% 100%);
        opacity: 0.82;
        pointer-events: none;
    }
}

@layer components {
    .auth-shell .auth-main {
        position: relative;
        z-index: 1;
        min-height: 100vh;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 2rem 1rem;
    }

    .auth-shell .auth-panel {
        width: 100%;
        max-width: 402px;
    }

    .auth-shell .auth-card {
        position: relative;
        background: #fff;
        border-radius: 4px;
        padding: 2.15rem 2.5rem 2.2rem;
        box-shadow: 0 18px 36px rgba(0, 0, 0, 0.28);
    }

    .auth-shell .auth-logo {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 0.8rem;
        margin-bottom: 1.9rem;
    }

    .auth-shell .auth-logo-mark {
        display: flex;
        gap: 0.3rem;
    }

    .auth-shell .auth-logo-block {
        width: 42px;
        height: 42px;
        display: grid;
        place-items: center;
        background: #1c4ad9;
        color: #fff;
        font-size: 1.95rem;
        font-weight: 800;
        line-height: 1;
        letter-spacing: -0.08em;
    }

    .auth-shell .auth-logo-text {
        color: #111;
        text-align: left;
        font-size: 1rem;
        line-height: 1;
        font-weight: 800;
    }

    .auth-shell .auth-logo-text div + div {
        margin-top: 0.1rem;
    }

    .auth-shell .auth-card-title {
        text-align: center;
        font-size: 1.02rem;
        font-weight: 700;
        color: #2d333b;
    }

    .auth-shell .auth-card-subtitle {
        margin-top: 1rem;
        text-align: center;
        font-size: 0.82rem;
        line-height: 1.5;
        color: #373f49;
    }

    .auth-shell .auth-copy {
        font-size: 0.82rem;
        line-height: 1.6;
        color: #4d5662;
    }

    .auth-shell .auth-copy-block {
        margin-top: 1rem;
        text-align: center;
    }

    .auth-shell .auth-status-banner {
        margin-top: 1rem;
        border-radius: 4px;
        border: 1px solid #bad1ff;
        background: #edf4ff;
        color: var(--dat-blue-deep);
        padding: 0.7rem 0.85rem;
        font-size: 0.8rem;
        font-weight: 600;
    }

    .auth-shell .auth-demo {
        margin-top: 1.25rem;
    }

    .auth-shell .auth-demo-grid {
        display: grid;
        gap: 0.55rem;
    }

    .auth-shell .auth-demo-item {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 0.75rem;
        border: 1px solid #d7e0ea;
        border-radius: 4px;
        background: #fafcff;
        padding: 0.68rem 0.8rem;
    }

    .auth-shell .auth-demo-label {
        font-size: 0.67rem;
        font-weight: 700;
        letter-spacing: 0.08em;
        text-transform: uppercase;
        color: #6b7280;
    }

    .auth-shell .auth-demo-cred {
        margin-top: 0.12rem;
        font-size: 0.83rem;
        font-weight: 600;
        color: #1e252d;
    }

    .auth-shell .auth-demo-pass {
        white-space: nowrap;
        border-radius: 999px;
        background: #edf4ff;
        color: #1c4ad9;
        padding: 0.34rem 0.62rem;
        font-size: 0.72rem;
        font-weight: 700;
    }

    .auth-shell .auth-form {
        margin-top: 1.3rem;
    }

  .auth-shell .auth-grid {
    display: block;
    /* gap: 0.9rem; */
    /* text-align: start; */
    width: 91%;
}
.auth-field {
    padding-bottom: 20px;
}
  .auth-shell .auth-field label {
    /* display: inline-block; */
    /* position: relative; */
    /* z-index: 1; */
    /* margin-bottom: -0.65rem; */
    /* margin-left: 0.8rem; */
    /* padding: 0 0.28rem; */
    /* background: #fff; */
    /* font-size: 0.74rem; */
    /* font-weight: 500; */
    color: #2d57ff;
    width: 100%;
    display: block;
    margin-bottom: 11px;
}
.auth-shell .auth-field input {
    /* width: 100%; */
    border: 2px solid #2d57ff;
    border-radius: 14px;
    background: #fff;
    padding: 0.92rem 1rem;
    font-size: 1rem;
    color: #1f2933;
    box-shadow: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    width: 100%;
    display: block;
}

    .auth-shell .auth-field input:focus {
        border-color: #1847ef;
        outline: none;
        box-shadow: 0 0 0 1px #1847ef;
    }

    .auth-shell .auth-checkrow {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 1rem;
        margin-top: 0.9rem;
        flex-wrap: wrap;
    }

    .auth-shell .auth-check {
        display: inline-flex;
        align-items: center;
        gap: 0.55rem;
        font-size: 0.84rem;
        color: #4c5561;
    }

    .auth-shell .auth-check input {
        width: 1rem;
        height: 1rem;
        border-radius: 0.3rem;
        border-color: #9bb5d1;
        color: #1c4ad9;
    }

    .auth-shell .auth-link {
        font-size: 0.82rem;
        font-weight: 500;
        color: #1c4ad9;
        text-decoration: none;
    }

    .auth-shell .auth-link:hover,
    .auth-shell .auth-footnote a:hover {
        text-decoration: underline;
    }

    .auth-shell .auth-submit {
        width: 100%;
        justify-content: center;
        margin-top: 1.2rem;
        border: 1px solid #2548ca;
        border-radius: 999px;
        background: linear-gradient(180deg, #3058de 0%, #294dcf 100%);
        padding: 0.97rem 1rem;
        font-size: 0.88rem;
        font-weight: 500;
        letter-spacing: 0.04em;
        text-transform: uppercase;
        color: #fff;
        box-shadow: none;
    }

    .auth-shell .auth-submit:hover {
        background: linear-gradient(180deg, #3861e7 0%, #2748c4 100%);
    }

    .auth-shell .auth-footnote {
        margin-top: 1.1rem;
        text-align: center;
        font-size: 0.82rem;
        color: #2f3742;
    }

    .auth-shell .auth-footnote a {
        color: #1c4ad9;
        font-weight: 600;
        text-decoration: none;
    }

    .auth-shell .auth-actions {
        margin-top: 1.2rem;
    }

    .auth-shell .auth-actions-stack {
        display: grid;
        gap: 0.85rem;
    }

    .auth-shell .auth-inline-form {
        width: 100%;
    }

    .auth-shell .auth-link-button {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 100%;
        border: 1px solid #cfd7e2;
        border-radius: 999px;
        background: #fff;
        padding: 0.9rem 1rem;
        font-size: 0.84rem;
        font-weight: 600;
        color: #425063;
        text-decoration: none;
        transition: border-color 0.2s ease, color 0.2s ease, background-color 0.2s ease;
    }

    .auth-shell .auth-link-button:hover {
        border-color: #1c4ad9;
        color: #1c4ad9;
        background: #f8fbff;
    }

    .auth-shell .auth-error {
        font-size: 0.8rem;
        color: #d32f2f;
    }

    @media (max-width: 480px) {
        .auth-shell .auth-card {
            padding: 1.8rem 1.3rem 1.8rem;
        }

        .auth-shell .auth-logo {
            transform: scale(0.92);
            transform-origin: center;
        }
    }
}
