:root {
    color-scheme: light;
    font-family: Arial, Helvetica, sans-serif;
    color: #0b0f17;
    font-synthesis: none;
    --red: #f50c20;
    --muted: #575b66;
}

* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    height: 100%;
}

button, input {
    font: inherit;
}

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

button, a {
    touch-action: manipulation;
}

button {
    cursor: pointer;
}

a {
    color: #ed0012;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

svg {
    display: block;
}

button:focus-visible, a:focus-visible {
    outline: 2px solid #f50c20;
    outline-offset: 3px;
}

.login-page {
    position: relative;
    height: 100vh;
    min-height: 100vh;
    overflow: hidden;
    background: #17181d;
}

.event-backdrop {
    position: absolute;
    inset: 0 32% 0 0;
    background-image: linear-gradient(180deg, rgba(0,0,0,.14) 0%, rgba(0,0,0,0) 24%, rgba(0,0,0,0) 49%, rgba(0,0,0,.74) 100%), url('../images/login/luxury-event.png');
    background-position: center, 48% center;
    background-size: cover;
}

/* Brand header */
.brand {
    position: absolute;
    z-index: 2;
    left: 3.45%;
    top: clamp(20px, 3.8vh, 42px);
    display: flex;
    align-items: center;
    gap: 1.1vw;
    color: white;
}

.brand-emblem {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    background: linear-gradient(#fff, #edf0f3);
    border: 1px solid #d9dde0;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.brand-emblem > .hesan-mark,
.brand-emblem img {
    width: 39px;
    height: 32px;
    border-radius: 5px;
}

.brand-name {
    display: block;
    font-size: clamp(15px, 1.25vw, 21px);
    font-weight: 700;
    letter-spacing: -.4px;
    text-shadow: 0 2px 8px rgba(0,0,0,0.45);
}

.brand-tagline {
    display: block;
    margin-top: 3px;
    font-size: clamp(10px, 0.82vw, 13px);
    letter-spacing: 3px;
    color: #d5d5db;
    text-shadow: 0 2px 8px rgba(0,0,0,0.45);
}

/* Hero left content */
.hero-content {
    position: absolute;
    z-index: 2;
    left: 3.6%;
    bottom: clamp(20px, 4.2vh, 45px);
    width: 53%;
    color: #fff;
}

.hero-title {
    font-size: clamp(26px, 2.6vw, 46px);
    line-height: 1.05;
    letter-spacing: -1.2px;
    font-weight: 750;
    margin: 0;
    text-shadow: 0 3px 10px rgba(0,0,0,0.4);
}

.hero-title span {
    display: block;
    margin-top: 4px;
    white-space: nowrap;
}

.hero-title em {
    font-style: normal;
    color: #ff2636;
}

.hero-rule {
    width: 45px;
    height: 3px;
    background: #ff1d30;
    margin: 10px 0 8px;
}

.hero-description {
    font-size: clamp(13px, 1.05vw, 17px);
    letter-spacing: .5px;
    color: #bcbcc4;
    margin: 0;
    line-height: 1.45;
}

.services {
    display: flex;
    gap: 14px;
    margin-top: 16px;
    list-style: none;
    padding: 0;
    margin-bottom: 0;
}

.services li {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 42px;
    padding: 8px 16px;
    border: 1px solid rgba(119, 119, 128, 0.6);
    border-radius: 12px;
    background: linear-gradient(110deg, rgba(37, 36, 41, 0.6), rgba(21, 22, 27, 0.69));
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(8px);
    font-size: 13.5px;
    font-weight: 600;
    white-space: nowrap;
}

.services svg {
    width: 22px;
    height: 22px;
    color: #ff0a24;
    stroke-width: 1.8;
}

/* Panel background art */
.panel-art {
    position: absolute;
    right: 0;
    top: 0;
    width: 43%;
    height: 100%;
    filter: drop-shadow(-8px 0 14px rgba(255, 17, 37, 0.5));
    pointer-events: none;
}

/* Login panel container */
.login-panel {
    position: relative;
    z-index: 3;
    margin-left: 66%;
    width: clamp(280px, 25.5vw, 360px);
    height: 100vh;
    max-height: 100vh;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    padding: clamp(12px, 2.2vh, 26px) 0;
}

.welcome-logo {
    width: 78px;
    height: 62px;
    align-self: center;
    mix-blend-mode: multiply;
    filter: drop-shadow(0 3px 2px rgba(0, 0, 0, 0.12));
}

.welcome-title {
    font-size: clamp(20px, 1.6vw, 25px);
    line-height: 1.2;
    letter-spacing: -0.6px;
    margin: 8px 0 3px;
    font-weight: 700;
}

.welcome-subtitle {
    font-size: clamp(12px, 0.88vw, 13.5px);
    line-height: 1.35;
    color: var(--muted);
    margin: 0;
}

.login-form {
    text-align: left;
    margin-top: clamp(14px, 2vh, 20px);
}

.field + .field {
    margin-top: clamp(9px, 1.3vh, 13px);
}

.field label {
    font-size: 13px;
    font-weight: 600;
    display: block;
    line-height: 18px;
    margin-bottom: 5px;
    color: #1e2229;
}

.input-shell {
    position: relative;
    display: flex;
    align-items: center;
}

.input-shell > .field-icon {
    position: absolute;
    left: 14px;
    width: 17px;
    height: 17px;
    color: #525763;
    pointer-events: none;
}

.input-shell input {
    width: 100%;
    height: 42px;
    padding: 0 40px 0 42px;
    border: 1.5px solid #d0d3da;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.8);
    color: #303642;
    font-size: 13.5px;
    outline: none;
    transition: border-color .2s, box-shadow .2s;
}

.input-shell input::placeholder {
    color: #787c89;
    opacity: 1;
}

.input-shell input:focus {
    border-color: #ee1224;
    box-shadow: 0 0 0 3px rgba(237, 16, 36, 0.12);
    background: #fff;
}

.input-shell input[aria-invalid=true] {
    border-color: #d40c21;
}

.input-shell input[type=password] {
    letter-spacing: 3px;
}

.input-shell input[type=password]::placeholder {
    letter-spacing: 3px;
    color: #535966;
}

.password-toggle {
    position: absolute;
    right: 8px;
    display: grid;
    place-items: center;
    border: 0;
    background: none;
    padding: 5px;
    color: #525763;
    border-radius: 4px;
}

.password-toggle svg {
    width: 17px;
    height: 17px;
}

.password-toggle[aria-pressed=true]::after {
    content: '';
    position: absolute;
    width: 19px;
    height: 2px;
    background: currentColor;
    transform: rotate(-45deg);
    box-shadow: 0 0 0 2px #fff;
}

.form-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: 10px;
    font-size: 12px;
    line-height: 18px;
    color: #555965;
}

.remember {
    display: flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
}

.remember input {
    appearance: none;
    width: 16px;
    height: 16px;
    border: 1.5px solid #c5c8cf;
    border-radius: 4px;
    margin: 0;
    background: #fff;
    display: grid;
    place-content: center;
    cursor: pointer;
}

.remember input:checked {
    background: var(--red);
    border-color: var(--red);
}

.remember input:checked::after {
    content: '';
    width: 8px;
    height: 4px;
    border-bottom: 2px solid white;
    border-left: 2px solid white;
    transform: translateY(-1px) rotate(-45deg);
}

.remember input:focus-visible {
    outline: 2px solid rgba(250, 108, 118, 0.5);
    outline-offset: 2px;
}

.forgot-password {
    font-size: 12px;
    font-weight: 500;
}

.submit-button {
    position: relative;
    width: 100%;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #ff5560;
    border-radius: 8px;
    background: linear-gradient(180deg, #fb1728 0%, #d40011 47%, #bd000b 100%);
    box-shadow: 0 5px 12px rgba(211, 0, 17, 0.25), inset 0 1px 1px rgba(255, 255, 255, 0.35);
    color: white;
    font-size: 14.5px;
    font-weight: 600;
    margin-top: 13px;
    transition: filter .2s, transform .2s;
}

.submit-button:hover {
    filter: brightness(1.07);
}

.submit-button:active {
    transform: translateY(1px);
}

.submit-button:disabled {
    opacity: .7;
    cursor: wait;
}

.submit-button svg {
    position: absolute;
    right: 16px;
    width: 17px;
    height: 17px;
    stroke-width: 2;
}

.support {
    margin-top: clamp(13px, 1.8vh, 18px);
    color: var(--muted);
    font-size: 12px;
}

.support-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    white-space: nowrap;
}

.support-divider::before,
.support-divider::after {
    content: '';
    height: 1px;
    background: #d8dbdf;
    flex: 1;
}

.admin-link {
    display: inline-flex;
    gap: 6px;
    align-items: center;
    margin-top: 6px;
    font-size: 12px;
    font-weight: 500;
}

.admin-link svg {
    width: 14px;
    height: 14px;
}

.copyright {
    font-size: 11px;
    color: #818591;
    margin: clamp(10px, 1.5vh, 16px) 0 0;
    padding-top: 0;
    line-height: 1.4;
}

.form-error {
    font-size: 12.5px;
    line-height: 1.4;
    border: 1px solid #ffc7ce;
    background: #fff1f3;
    color: #ae1021;
    padding: 8px 12px;
    border-radius: 7px;
    margin: 0 0 12px;
}

.field-error {
    font-size: 12px;
    line-height: 1.35;
    margin: 4px 0 0;
    color: #b50015;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Extra large screens */
@media (min-width: 1800px) {
    .login-panel {
        max-width: 390px;
        margin-left: auto;
        margin-right: 5%;
    }
}

/* Shorter screens (like 1366x768 laptops or smaller browser viewports) */
@media (max-height: 720px) and (min-width: 901px) {
    .login-panel {
        padding: 8px 0;
    }
    .welcome-logo {
        width: 68px;
        height: 54px;
    }
    .welcome-title {
        font-size: 19px;
        margin: 6px 0 2px;
    }
    .welcome-subtitle {
        font-size: 11.5px;
    }
    .login-form {
        margin-top: 10px;
    }
    .field + .field {
        margin-top: 8px;
    }
    .field label {
        font-size: 12px;
        margin-bottom: 3px;
    }
    .input-shell input {
        height: 38px;
        font-size: 13px;
        border-radius: 7px;
    }
    .form-options {
        margin-top: 8px;
        font-size: 11.5px;
    }
    .submit-button {
        height: 38px;
        font-size: 13.5px;
        margin-top: 10px;
        border-radius: 7px;
    }
    .support {
        margin-top: 10px;
    }
    .copyright {
        margin-top: 8px;
        font-size: 10.5px;
    }
    .hero-title {
        font-size: clamp(24px, 2.4vw, 38px);
    }
    .hero-description {
        font-size: 13px;
    }
    .services li {
        min-height: 36px;
        padding: 6px 12px;
        font-size: 12px;
    }
}

/* Mobile & Tablet layout */
@media (max-width: 900px) {
    html, body {
        height: auto;
        overflow-y: auto;
    }
    .login-page {
        height: auto;
        min-height: 100svh;
        overflow-y: auto;
        display: flex;
        flex-direction: column;
        background: #f7f8fa;
    }
    .event-backdrop {
        inset: 0 0 auto;
        height: 380px;
        background-position: center, center 48%;
        background-image: linear-gradient(180deg, rgba(0,0,0,.08) 0%, rgba(0,0,0,.1) 24%, rgba(0,0,0,.4) 45%, rgba(0,0,0,.72) 100%), url('../images/login/luxury-event.png');
    }
    .brand {
        position: relative;
        left: auto;
        top: auto;
        margin: 20px 20px;
        gap: 12px;
    }
    .brand-emblem {
        width: 42px;
        height: 42px;
        border-radius: 9px;
    }
    .brand-emblem > .hesan-mark,
    .brand-emblem img {
        width: 35px;
        height: 29px;
    }
    .brand-name {
        font-size: 16px;
    }
    .brand-tagline {
        font-size: 10px;
        letter-spacing: 2.5px;
    }
    .hero-content {
        position: relative;
        left: auto;
        bottom: auto;
        width: auto;
        padding: 60px 20px 24px;
    }
    .hero-title {
        font-size: 28px;
        letter-spacing: -0.8px;
        line-height: 1.1;
    }
    .hero-title span {
        white-space: normal;
    }
    .hero-rule {
        height: 3px;
    }
    .hero-description {
        font-size: 13.5px;
        color: #ededf1;
        text-shadow: 0 2px 6px rgba(0,0,0,0.6);
    }
    .services {
        gap: 8px;
        margin-top: 14px;
        flex-wrap: wrap;
    }
    .services li {
        font-size: 11.5px;
        padding: 7px 12px;
        gap: 8px;
        min-height: 36px;
        border-radius: 9px;
        min-width: 0;
    }
    .services svg {
        width: 18px;
        height: 18px;
    }
    .panel-art {
        display: none;
    }
    .login-panel {
        margin: 0;
        width: 100%;
        height: auto;
        max-height: none;
        padding: 28px max(20px, calc((100vw - 420px) / 2)) 24px;
        background: radial-gradient(ellipse at 100% 0, #ffe5e8 0, transparent 40%), #fafbfc;
        border-top: 3px solid #f51b2c;
        border-radius: 24px 24px 0 0;
        box-shadow: 0 -10px 30px rgba(166, 0, 22, 0.18);
    }
    .welcome-logo {
        width: 74px;
        height: 58px;
    }
    .welcome-title {
        font-size: 23px;
        margin: 10px 0 4px;
    }
    .welcome-subtitle {
        font-size: 13px;
        margin: 0;
    }
    .login-form {
        margin-top: 16px;
    }
    .field label {
        font-size: 13px;
    }
    .input-shell input {
        font-size: 13.5px;
        height: 42px;
        padding-left: 42px;
    }
    .input-shell > .field-icon {
        left: 14px;
        width: 17px;
    }
    .form-options {
        font-size: 12px;
    }
    .submit-button {
        font-size: 14.5px;
        height: 42px;
    }
    .support {
        font-size: 12px;
        margin-top: 18px;
    }
    .copyright {
        font-size: 11px;
        padding-top: 0;
        margin-top: 16px;
    }
}

@media (max-width: 390px) {
    .brand {
        margin: 16px 16px;
        gap: 10px;
    }
    .brand-name {
        font-size: 14px;
    }
    .brand-tagline {
        font-size: 9px;
        letter-spacing: 2px;
    }
    .hero-content {
        padding: 50px 16px 20px;
    }
    .hero-title {
        font-size: 24px;
    }
    .hero-description {
        font-size: 12.5px;
    }
    .services {
        gap: 6px;
    }
    .services li {
        padding: 6px 9px;
        font-size: 11px;
        gap: 6px;
    }
    .login-panel {
        padding-left: 16px;
        padding-right: 16px;
    }
    .welcome-title {
        font-size: 21px;
    }
    .welcome-subtitle {
        font-size: 12px;
    }
}

@media (prefers-reduced-motion: reduce) {
    * {
        transition: none !important;
    }
}
