:root {
    --yp-bg: #ffffff;
    --yp-gold: #b8921f;
    --yp-gold-bright: #c9a227;
    --yp-text: #121212;
    --yp-muted: #5f5a51;
    --yp-line: rgba(184, 146, 31, 0.28);
    --yp-shadow: 0 24px 60px rgba(18, 18, 18, 0.08);
    --yp-font-display: "Syne", sans-serif;
    --yp-font-body: "Outfit", sans-serif;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    min-height: 100%;
    font-family: var(--yp-font-body);
    color: var(--yp-text);
    background: #fff;
    overflow-x: hidden;
}

.yp-bg {
    position: fixed;
    inset: 0;
    z-index: -2;
    background: linear-gradient(180deg, #ffffff 0%, #fbfaf7 50%, #ffffff 100%);
}

.yp-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0.35;
    background-image:
        linear-gradient(rgba(184, 146, 31, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(184, 146, 31, 0.06) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: radial-gradient(ellipse at 50% 30%, black 15%, transparent 70%);
}

.yp-glow {
    position: fixed;
    z-index: -1;
    width: 40vw;
    height: 40vw;
    border-radius: 50%;
    filter: blur(70px);
    opacity: 0.32;
    pointer-events: none;
    animation: yp-float 11s ease-in-out infinite;
}

.yp-glow-a {
    top: -10%;
    right: -8%;
    background: rgba(201, 162, 39, 0.28);
}

.yp-glow-b {
    bottom: 5%;
    left: -12%;
    background: rgba(201, 162, 39, 0.14);
    animation-delay: -3.5s;
}

.yp-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 5vw;
    position: sticky;
    top: 0;
    z-index: 10;
    backdrop-filter: blur(12px);
    background: rgba(255, 255, 255, 0.88);
    border-bottom: 1px solid var(--yp-line);
}

.yp-nav-brand img {
    display: block;
    height: 40px;
    width: auto;
    max-width: 170px;
    object-fit: contain;
    border-radius: 8px;
}

.yp-nav-link {
    color: var(--yp-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.2s ease;
}

.yp-nav-link:hover {
    color: var(--yp-gold);
}

.yp-login {
    min-height: calc(100vh - 74px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2.5rem 1.25rem 3rem;
}

.yp-login-card {
    width: 100%;
    max-width: 440px;
    padding: 2rem 1.75rem 1.85rem;
    border-radius: 22px;
    border: 1px solid var(--yp-line);
    background: linear-gradient(180deg, #ffffff, #fbfaf7);
    box-shadow: var(--yp-shadow);
}

.yp-login-logo {
    display: block;
    height: 64px;
    width: auto;
    max-width: 240px;
    object-fit: contain;
    border-radius: 12px;
    margin: 0 auto 1.25rem;
    box-shadow: 0 0 0 1px var(--yp-line), 0 14px 30px rgba(18, 18, 18, 0.06);
}

.yp-eyebrow {
    margin: 0 0 0.55rem;
    text-align: center;
    color: var(--yp-gold);
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.yp-login-card h1 {
    margin: 0 0 0.55rem;
    text-align: center;
    font-family: var(--yp-font-display);
    font-size: clamp(1.8rem, 4vw, 2.25rem);
    letter-spacing: -0.03em;
    line-height: 1.15;
}

.yp-sub {
    margin: 0 0 1.35rem;
    text-align: center;
    color: var(--yp-muted);
    font-size: 0.98rem;
}

.yp-flashes {
    margin-bottom: 0.85rem;
}

.yp-flashes .alert {
    margin: 0 0 0.65rem;
    padding: 0.75rem 0.9rem;
    border-radius: 12px;
    font-size: 0.92rem;
    text-align: left;
    border: 1px solid transparent;
}

.yp-flashes .alert i {
    margin-right: 0.4rem;
}

.yp-flashes .alert-success {
    background: #eefaf4;
    color: #1d6b45;
    border-color: #c7ebd7;
}

.yp-flashes .alert-danger {
    background: #fff1f0;
    color: #a33;
    border-color: #f0cfcb;
}

.yp-flashes .alert-warning {
    background: #fff8e8;
    color: #8a6d1d;
    border-color: #f0e0b0;
}

.yp-flashes .alert-info {
    background: #eef7ff;
    color: #1f5f8a;
    border-color: #c9e2f5;
}

.yp-form {
    display: grid;
    gap: 0.95rem;
}

.yp-field {
    display: grid;
    gap: 0.4rem;
}

.yp-field span {
    font-size: 0.86rem;
    font-weight: 600;
    color: var(--yp-text);
}

.yp-field input {
    width: 100%;
    border: 1px solid rgba(18, 18, 18, 0.12);
    background: #fff;
    border-radius: 12px;
    padding: 0.9rem 1rem;
    font-size: 1rem;
    font-family: var(--yp-font-body);
    color: var(--yp-text);
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.yp-field input::placeholder {
    color: #9a9488;
}

.yp-field input:focus {
    border-color: var(--yp-gold);
    box-shadow: 0 0 0 4px rgba(201, 162, 39, 0.15);
}

.yp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin-top: 0.35rem;
    border: 0;
    border-radius: 999px;
    padding: 0.95rem 1.2rem;
    font-family: var(--yp-font-body);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.yp-btn:hover {
    transform: translateY(-2px);
}

.yp-btn-solid {
    background: linear-gradient(135deg, #d4b13a, var(--yp-gold));
    color: #111;
    box-shadow: 0 12px 28px rgba(184, 146, 31, 0.28);
}

.yp-btn-shine {
    position: relative;
    overflow: hidden;
}

.yp-btn-shine::before {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 70%;
    height: 100%;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.55), transparent);
    transform: skewX(-20deg);
    transition: left 0.55s ease;
}

.yp-btn-shine:hover::before {
    left: 140%;
}

.yp-login-foot {
    margin: 1.5rem 0 0;
    color: var(--yp-muted);
    font-size: 0.86rem;
    text-align: center;
}

.yp-anim {
    opacity: 0;
    transform: translateY(16px);
    animation: yp-rise 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    animation-delay: var(--d, 0s);
}

@keyframes yp-rise {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes yp-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

@media (max-width: 520px) {
    .yp-login-card {
        padding: 1.6rem 1.2rem 1.45rem;
        border-radius: 18px;
    }

    .yp-nav-link {
        font-size: 0.88rem;
    }

    .yp-login-logo {
        height: 56px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation: none !important;
        transition: none !important;
    }
    .yp-anim {
        opacity: 1 !important;
        transform: none !important;
    }
}
