:root {
    --slp-bg-1: #241065;
    --slp-bg-2: #45248f;
    --slp-bg-3: #6d47d0;
    --slp-text: #ffffff;
    --slp-soft: rgba(255, 255, 255, 0.82);
    --slp-panel: rgba(117, 85, 207, 0.25);
    --slp-panel-border: rgba(255, 255, 255, 0.20);
    --slp-input-bg: #f7f4fe;
    --slp-input-text: #43346e;
    --slp-shadow: 0 20px 40px rgba(16, 9, 44, 0.30);
    --slp-card-bg-image: none;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body.slp-body {
    min-height: 100vh;
    font-family: Arial, Helvetica, sans-serif;
    color: var(--slp-text);
    background: radial-gradient(circle at top, rgba(255,255,255,0.25), transparent 16%), linear-gradient(180deg, var(--slp-bg-1) 0%, var(--slp-bg-2) 48%, var(--slp-bg-3) 100%);
}

a { color: inherit; }
button, input, select, textarea { font: inherit; }

.slp-app {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: stretch;
}

.slp-phone-frame {
    width: 100%;
    max-width: 430px;
    min-height: 100vh;
    position: relative;
    overflow: hidden;
    background: transparent;
}

.slp-screen {
    display: none;
    min-height: 100vh;
    padding: 24px 22px 36px;
    position: relative;
}

.slp-screen.is-active { display: block; }

.slp-glow-top {
    position: absolute;
    top: -84px;
    left: 50%;
    transform: translateX(-50%);
    width: 92%;
    height: 160px;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(255,255,255,0.45) 0%, rgba(255,255,255,0) 72%);
    filter: blur(10px);
    opacity: 0.85;
    pointer-events: none;
}

.slp-stars,
.slp-stars::before,
.slp-stars::after {
    position: absolute;
    content: "";
    inset: 0;
    background-image:
        radial-gradient(circle at 7% 26%, rgba(255,255,255,0.95) 0 2px, transparent 3px),
        radial-gradient(circle at 93% 26%, rgba(255,255,255,0.9) 0 2px, transparent 3px),
        radial-gradient(circle at 13% 55%, rgba(255,255,255,0.85) 0 2px, transparent 3px),
        radial-gradient(circle at 89% 57%, rgba(255,255,255,0.85) 0 2px, transparent 3px);
    pointer-events: none;
}

.slp-hero {
    position: relative;
    z-index: 2;
    text-align: center;
    padding-top: 48px;
    margin-bottom: 18px;
}

.slp-hero-small { padding-top: 30px; }

.slp-hero-script,
.slp-card-brand-script {
    margin: 0;
    font-size: 2.7rem;
    font-style: italic;
    font-weight: 700;
    line-height: 0.9;
    letter-spacing: 0.02em;
    text-shadow: 0 6px 15px rgba(0,0,0,0.24);
}

.slp-hero-title,
.slp-card-brand-title {
    margin: 8px 0 0;
    font-size: 1.95rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    text-shadow: 0 6px 15px rgba(0,0,0,0.24);
}

.slp-hero-line {
    display: block;
    width: 62px;
    height: 3px;
    border-radius: 999px;
    margin: 14px auto 0;
    background: rgba(255,255,255,0.84);
}

.slp-panel {
    position: relative;
    z-index: 2;
    margin-top: 22px;
    padding: 28px 18px 22px;
    border-radius: 18px;
    background: var(--slp-panel);
    border: 1px solid var(--slp-panel-border);
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.06);
    backdrop-filter: blur(4px);
}

.slp-panel-result { padding-top: 20px; }

.slp-form {
    display: grid;
    gap: 18px;
}

.slp-field label {
    display: block;
    margin-bottom: 8px;
    text-transform: uppercase;
    font-weight: 700;
    font-size: 0.92rem;
    letter-spacing: 0.03em;
}

.slp-field input,
.slp-field select {
    width: 100%;
    border: 0;
    border-radius: 12px;
    background: var(--slp-input-bg);
    color: var(--slp-input-text);
    padding: 15px 16px;
    font-size: 1rem;
    font-weight: 700;
    outline: none;
    box-shadow: inset 0 0 0 1px rgba(53, 42, 89, 0.04);
}

.slp-field input::placeholder { color: rgba(58, 48, 97, 0.65); }

.slp-button {
    width: 100%;
    border: 0;
    border-radius: 999px;
    min-height: 54px;
    font-size: 1.08rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    cursor: pointer;
}

.slp-button.is-loading { opacity: 0.7; pointer-events: none; }

.slp-button-primary,
.slp-button-secondary,
.slp-button-zalo {
    background: linear-gradient(180deg, #ffffff 0%, #efe6ff 100%);
    color: #432a96;
    box-shadow: 0 12px 24px rgba(23, 9, 61, 0.22), inset 0 0 0 2px rgba(101, 62, 206, 0.24);
}

.slp-button-zalo {
    margin-top: 10px;
    background: linear-gradient(180deg, #fff8d8 0%, #f5df88 100%);
    color: #5f4800;
}

.slp-button-link {
    margin-top: 10px;
    min-height: 42px;
    background: transparent;
    color: rgba(255,255,255,0.92);
    box-shadow: none;
    text-transform: none;
    font-size: 0.98rem;
}

.slp-message {
    display: none;
    margin-top: 14px;
    border-radius: 12px;
    padding: 12px 14px;
    font-size: 0.95rem;
    line-height: 1.45;
}

.slp-message.is-visible { display: block; }
.slp-message.is-success { background: rgba(25, 164, 119, 0.18); border: 1px solid rgba(146, 255, 215, 0.28); }
.slp-message.is-error { background: rgba(204, 65, 106, 0.18); border: 1px solid rgba(255, 168, 191, 0.28); }
.slp-message.is-warning { background: rgba(255, 193, 80, 0.14); border: 1px solid rgba(255, 224, 163, 0.28); }

.slp-result-heading {
    text-align: center;
    margin-bottom: 16px;
}

.slp-result-heading strong {
    display: block;
    font-size: 1.06rem;
    margin-bottom: 8px;
}

.slp-result-heading p {
    margin: 0;
    color: var(--slp-soft);
    font-size: 0.94rem;
}

.slp-card-wrap {
    display: flex;
    justify-content: center;
    margin-bottom: 18px;
}

.slp-card-preview {
    width: 100%;
    max-width: 298px;
}

.slp-card-art {
    position: relative;
    min-height: 190px;
    border-radius: 16px;
    padding: 18px 18px 16px;
    background: linear-gradient(135deg, #fff1b5 0%, #d7b66b 48%, #f7e1a3 100%);
    box-shadow: 0 16px 28px rgba(15, 8, 42, 0.30);
    overflow: hidden;
}

.slp-card-art.has-image {
    background-image: var(--slp-card-bg-image);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.slp-card-art::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, rgba(255,255,255,0.08), transparent 35%, rgba(255,255,255,0.06) 60%, transparent 100%);
    pointer-events: none;
}

.slp-card-brand {
    position: relative;
    z-index: 1;
    max-width: 66%;
    color: #fff8e7;
    text-shadow: 0 3px 8px rgba(102, 77, 8, 0.25);
}

.slp-card-brand-script {
    font-size: 1.6rem;
}

.slp-card-brand-title {
    font-size: 0.72rem;
    margin-top: 2px;
    letter-spacing: 0.15em;
}

.slp-card-body {
    position: absolute;
    left: 18px;
    right: 18px;
    bottom: 16px;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
}

.slp-card-name {
    flex: 1;
    color: #1c1919;
    font-size: 1.12rem;
    font-weight: 800;
    text-transform: uppercase;
    line-height: 1.25;
}

.slp-card-code-block {
    min-width: 84px;
    text-align: right;
    color: #4a3904;
}

.slp-card-code-block span {
    display: block;
    font-size: 0.72rem;
    text-transform: uppercase;
    opacity: 0.9;
}

.slp-card-code-block strong {
    display: block;
    margin-top: 4px;
    font-size: 1.5rem;
    letter-spacing: 0.05em;
}

.slp-confirm-box {
    border-radius: 14px;
    padding: 14px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.16);
}

.slp-confirm-title {
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-bottom: 8px;
}

.slp-confirm-box p {
    margin: 0 0 10px;
    color: var(--slp-soft);
    font-size: 0.93rem;
    line-height: 1.45;
}

.slp-confirm-code {
    display: block;
    border-radius: 12px;
    padding: 12px 14px;
    background: #f6f4fb;
    color: #33266d;
    font-weight: 800;
    text-align: center;
    letter-spacing: 0.05em;
}

.slp-result-actions {
    margin-top: 16px;
}

.slp-message-inline { margin-top: 16px; }

.slp-fallback-wrap {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
}

.slp-fallback-box {
    max-width: 560px;
    padding: 24px;
    border-radius: 16px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.14);
}

@media (max-width: 360px) {
    .slp-screen { padding: 20px 16px 32px; }
    .slp-hero-script { font-size: 2.35rem; }
    .slp-hero-title { font-size: 1.7rem; }
}
