/* ===== Base / Reset ===== */
*, *::before, *::after {
    box-sizing: border-box
}

html, body {
    height: 100%
}

body {
    margin: 0;
    font-family: system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ===== Outer background + phone width ===== */
.offer-bg {
    min-height: 100%;
    background: #eef2f6;
    display: flex;
    align-items: center;
    justify-content: center;
}

.phone {
    width: 360px;
    max-width: 100%
}

/* ===== Alerts ===== */
.alert-error {
    background: #fff4f4;
    color: #7a1e1e;
    border: 1px solid #f3c2c2;
    border-radius: 10px;
    padding: 10px 12px;
    margin-bottom: 12px;
    font-size: 14px;
}

/* ===== Shell ===== */
.shell {
    position: relative;
    background: #fff;
    border-radius: 22px;
    box-shadow: 0 10px 22px rgba(0,0,0,.10);
    padding: 14px 18px 18px;
}

/* ===== Brand ===== */
.brand {
    margin: 0 0 32px 0;
    position: relative;
    z-index: 3
}

.brand-logo {
    width: 144px;
    height: 33px;
    display: block
}

/* ===== Gray Panel ===== */
.panel {
    position: relative;
    background: #f5f6fa;
    border-radius: 18px;
    padding: 48px 16px 16px;
    text-align: center;
}

/* ===== Avatar ===== */
.avatar-wrap {
    position: absolute;
    left: 50%;
    top: 8px;
    transform: translate(-50%, -50%);
    width: 74px;
    height: 74px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 6px 16px rgba(0,0,0,.12);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    border: 6px solid #f5f6fa;
}

.avatar {
    width: 62px;
    height: 62px;
    border-radius: 50%;
    object-fit: cover
}

/* ===== Titles ===== */
.biz-name {
    margin-top: 6px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .55px;
    color: #2d2f36;
    text-transform: uppercase;
}

.verified {
    display: inline-block;
    width: 10px;
    height: 10px;
    margin-left: 6px;
    border-radius: 50%;
    background: #22c55e;
    vertical-align: middle
}

.offer-title {
    margin: 12px 0 6px;
    font-size: 26px;
    font-weight: 900;
    color: #0a0f2c
}

.offer-desc {
    margin: 0 0 16px;
    color: #1c4fa1;
    font-weight: 800;
    font-size: 12px;
    text-transform: uppercase;
    line-height: 1.35
}

/* ===== Login form ===== */
.login-form {
    text-align: left
}

/* Input (with lock icon) */
.text-input {
    display: block;
    width: 100%;
    height: 48px;
    border: 1px solid #e2e5ea;
    border-radius: 12px;
    background: #fff;
    padding: 0 12px 0 44px;
    font-size: 14px;
    color: #0a0f2c;
    outline: none;
    background-repeat: no-repeat;
    background-position: 14px center;
    background-size: 18px 18px;
    background-image: url("data:image/svg+xml;utf8,\
<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239aa3b2' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'>\
<rect x='3' y='11' width='18' height='10' rx='2' ry='2'/>\
<path d='M7 11V7a5 5 0 0 1 10 0v4'/>\
</svg>");
}

    .text-input::placeholder {
        color: #9aa3b2
    }

/* ===== Buttons ===== */
.btn-primary {
    width: 100%;
    height: 48px;
    border: none;
    border-radius: 12px;
    background: #2b61b8;
    color: #fff;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    transition: background .15s ease-in-out, transform .02s;
}

    .btn-primary:hover {
        background: #2758a7
    }

    .btn-primary:active {
        transform: translateY(1px)
    }

.login-form .btn-primary {
    margin-top: 8px
}

.btn-outline {
    width: 100%;
    height: 48px;
    border-radius: 12px;
    background: #fff;
    color: #2b61b8;
    border: 2px solid #2b61b8;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
}

    .btn-outline:hover {
        background: #f5f6fa
    }

/* Actions area */
.actions {
    display: flex;
    gap: 12px;
    margin-top: 20px;
    align-items: stretch
}

    .actions .btn-primary, .actions .btn-outline {
        flex: 1;
        margin-top: 0
    }

/* ===== Remember ===== */
.remember {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #6b7380;
    margin-top: 12px;
    user-select: none;
}

    .remember input {
        width: 16px;
        height: 16px
    }

/* ===== Extra info rows ===== */
.user-info {
    margin: 16px 0;
    font-weight: 700;
    font-size: 14px;
    color: #0a0f2c
}

.dates-row {
    display: flex;
    justify-content: space-between;
    margin: 16px 0;
    padding-top: 12px;
    border-top: 1px solid #e2e5ea;
    font-size: 13px;
}

    .dates-row .label {
        display: block;
        color: #6b7380;
        font-size: 12px
    }

    .dates-row .value {
        margin-top: 4px;
        font-weight: 600
    }

.status-active {
    color: #22c55e
}

/* ===== Success / Used messages ===== */
.success-msg {
    margin: 20px 0;
    color: #16a34a;
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    line-height: 1.4;
}

.success-icon {
    font-size: 64px;
    color: #22c55e;
    margin: 20px 0
}

.used-msg {
    margin: 20px 0;
    color: #dc2626;
    font-weight: 800;
    font-size: 14px;
    text-transform: uppercase;
    line-height: 1.4;
}

/* ===== Not found ===== */
.notfound-box {
    margin: 8px 0 22px;
    height: 180px;
    background: #eef1f6;
    border: 3px solid #3b82f6;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.6);
}

    .notfound-box span {
        color: #2563eb;
        font-weight: 800;
        font-size: 18px;
        letter-spacing: .3px;
        text-transform: uppercase;
    }

/* ===== Close button outside the panel (NotFound/Used/Success) ===== */
.outside-close {
    margin-top: 16px;
    justify-content: center
}

    .outside-close .btn-outline {
        flex: 0 0 160px
    }

/* ===== Small screens ===== */
@media (max-width:380px) {
    .phone {
        width: 100%;
        padding: 0 10px
    }

    .shell {
        padding: 12px 14px 14px
    }

    .panel {
        padding: 48px 12px 12px
    }
}
