/*
 * TURKSEED auth pages (login, forgot/reset password, register, application).
 * Look taken from the test site (black starfield, glass card, cyan/magenta neon, stacked buttons),
 * rebuilt as a standalone static stylesheet: the site CSP allows only 'self' fonts/scripts, so no CDN.
 * Not part of the Vite build; shared by resources/views/auth/partials/ts-head.blade.php.
 */

:root {
    --ts-bg: #000;
    --ts-text: #fff;
    --ts-muted: rgba(255, 255, 255, 0.78);
    --ts-faint: rgba(255, 255, 255, 0.55);
    --ts-glass: rgba(255, 255, 255, 0.08);
    --ts-glass-border: rgba(255, 255, 255, 0.2);
    --ts-field: rgba(255, 255, 255, 0.12);
    --ts-field-border: rgba(255, 255, 255, 0.18);
    --ts-cyan: #00ffff;
    --ts-magenta: #ff00cc;
    --ts-blue: #3333ff;
    --ts-sky: #00aaff;
    --ts-telegram: #0088cc;
    --ts-telegram-hover: #00a2e8;
    --ts-gold: #ffc107;
    --ts-green: #00ff7f;
    --ts-red: #ff5a5a;
    --ts-radius: 10px;
    --ts-font: 'Segoe UI', system-ui, -apple-system, Roboto, 'Helvetica Neue', Arial, sans-serif;
    color-scheme: dark;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    padding: 24px 16px;
    background:
        radial-gradient(ellipse 60% 45% at 15% 10%, rgba(0, 255, 255, 0.12), transparent 70%),
        radial-gradient(ellipse 55% 45% at 85% 90%, rgba(255, 0, 204, 0.14), transparent 70%),
        radial-gradient(ellipse 40% 35% at 90% 15%, rgba(51, 51, 255, 0.14), transparent 70%),
        var(--ts-bg);
    background-attachment: fixed;
    color: var(--ts-text);
    font-family: var(--ts-font);
    font-size: 15px;
    line-height: 1.5;
}

/* Starfield (test site look, CSS only — no video download) */
.ts-stars {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background-image:
        radial-gradient(rgba(255, 255, 255, 0.9) 1px, transparent 1px),
        radial-gradient(rgba(255, 255, 255, 0.5) 1px, transparent 1px);
    background-size: 50px 50px, 90px 90px;
    background-position: 0 0, 25px 40px;
    opacity: 0.18;
    animation: ts-stars 140s linear infinite;
}

@keyframes ts-stars {
    to {
        background-position: 1500px 750px, 1025px 1240px;
    }
}

.ts-main {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 460px;
    margin: auto;
}

.ts-main--wide {
    max-width: 640px;
}

.ts-card {
    padding: 32px 28px;
    border: 1px solid var(--ts-glass-border);
    border-radius: 20px;
    background: var(--ts-glass);
    -webkit-backdrop-filter: blur(25px);
    backdrop-filter: blur(25px);
    box-shadow: 0 0 60px rgba(0, 0, 0, 0.8);
    animation: ts-fade-in 0.8s ease both;
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .ts-card {
        background: rgba(18, 18, 28, 0.94);
    }
}

@keyframes ts-fade-in {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}

/* ---------- Brand ---------- */
.ts-brand {
    display: block;
    margin: 4px auto 22px;
    text-align: center;
    border-radius: var(--ts-radius);
}

.ts-brand img {
    display: block;
    width: 100%;
    max-width: 300px;
    height: auto;
    margin: 0 auto;
    filter: drop-shadow(0 0 15px rgba(0, 255, 255, 0.45));
}

.ts-page-title {
    margin: -6px 0 20px;
    text-align: center;
    font-size: 19px;
    font-weight: 800;
    letter-spacing: 0.3px;
    background: linear-gradient(135deg, var(--ts-cyan), var(--ts-magenta));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.ts-lead {
    margin: -8px 0 20px;
    text-align: center;
    color: var(--ts-muted);
    font-size: 14px;
}

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

/* ---------- Form ---------- */
.ts-form {
    margin: 0;
}

.ts-form--spaced {
    margin-top: 20px;
}

.ts-field {
    margin: 0 0 16px;
}

.ts-label {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 7px;
    color: var(--ts-cyan);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.6px;
    text-transform: uppercase;
}

.ts-input-wrap {
    position: relative;
    display: block;
}

.ts-input-wrap > .ts-input-icon {
    position: absolute;
    top: 50%;
    left: 13px;
    width: 18px;
    height: 18px;
    transform: translateY(-50%);
    color: var(--ts-magenta);
    pointer-events: none;
}

.ts-input,
.ts-select,
.ts-textarea {
    display: block;
    width: 100%;
    min-height: 46px;
    padding: 12px 14px;
    border: 1px solid var(--ts-field-border);
    border-radius: var(--ts-radius);
    background: var(--ts-field);
    color: var(--ts-text);
    font: inherit;
    font-size: 16px; /* 16px keeps iOS from zooming on focus */
    transition:
        border-color 0.2s,
        box-shadow 0.2s,
        background-color 0.2s;
}

.ts-input--icon {
    padding-left: 42px;
}

.ts-input--with-toggle {
    padding-right: 48px;
}

.ts-textarea {
    min-height: 120px;
    resize: vertical;
}

.ts-select {
    appearance: none;
    padding-right: 40px;
    background-image:
        linear-gradient(45deg, transparent 50%, var(--ts-cyan) 50%),
        linear-gradient(135deg, var(--ts-cyan) 50%, transparent 50%);
    background-position:
        calc(100% - 20px) 50%,
        calc(100% - 14px) 50%;
    background-size: 6px 6px;
    background-repeat: no-repeat;
}

.ts-select option {
    background: #111;
    color: #fff;
}

.ts-input::placeholder,
.ts-textarea::placeholder {
    color: var(--ts-faint);
}

.ts-input:focus,
.ts-select:focus,
.ts-textarea:focus {
    outline: none;
    border-color: var(--ts-magenta);
    background-color: rgba(255, 255, 255, 0.16);
    box-shadow: 0 0 0 1px var(--ts-magenta), 0 0 14px rgba(255, 0, 204, 0.55);
}

.ts-input[aria-invalid='true'] {
    border-color: var(--ts-red);
    box-shadow: 0 0 0 1px var(--ts-red);
}

.ts-toggle {
    position: absolute;
    top: 50%;
    right: 6px;
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--ts-muted);
    cursor: pointer;
    transform: translateY(-50%);
}

.ts-toggle:hover {
    color: var(--ts-cyan);
}

.ts-toggle svg {
    width: 20px;
    height: 20px;
}

.ts-toggle[hidden],
.ts-toggle svg[hidden] {
    display: none;
}

.ts-hint {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    margin-top: 7px;
    color: var(--ts-faint);
    font-size: 13px;
}

.ts-hint[hidden] {
    display: none;
}

.ts-hint svg {
    flex: none;
    width: 15px;
    height: 15px;
    margin-top: 2px;
}

.ts-hint--error {
    color: #ffb3b3;
}

.ts-hint--error strong {
    color: #fff;
}

.ts-check {
    display: flex;
    align-items: center;
    gap: 9px;
    margin: 4px 0 20px;
    font-size: 14px;
}

.ts-check__input {
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: var(--ts-magenta);
    cursor: pointer;
}

.ts-check__label {
    cursor: pointer;
    color: var(--ts-muted);
}

/* ---------- Buttons ---------- */
.ts-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    width: 100%;
    min-height: 46px;
    padding: 11px 14px;
    border: 1px solid transparent;
    border-radius: var(--ts-radius);
    color: #fff;
    font: inherit;
    font-size: 15px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition:
        transform 0.2s,
        box-shadow 0.2s,
        background-color 0.2s,
        border-color 0.2s;
}

.ts-btn svg {
    flex: none;
    width: 18px;
    height: 18px;
}

.ts-btn:hover {
    transform: scale(1.02);
}

.ts-btn--primary {
    min-height: 50px;
    background: linear-gradient(45deg, var(--ts-magenta), var(--ts-blue));
    font-size: 16px;
    font-weight: 800;
    letter-spacing: 0.8px;
    text-transform: uppercase;
}

.ts-btn--primary:hover {
    box-shadow: 0 0 22px rgba(255, 0, 204, 0.75);
}

.ts-btn--glass {
    border-color: rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.14);
    font-weight: 500;
}

.ts-btn--glass:hover {
    border-color: var(--ts-magenta);
    background: rgba(255, 255, 255, 0.22);
    box-shadow: 0 0 15px rgba(255, 0, 204, 0.3);
}

.ts-btn--gray {
    background: #444;
}

.ts-btn--gray:hover {
    background: #5c5c5c;
}

.ts-btn--telegram {
    background: var(--ts-telegram);
    font-weight: 700;
}

.ts-btn--telegram:hover {
    background: var(--ts-telegram-hover);
    box-shadow: 0 0 18px rgba(0, 162, 232, 0.5);
}

.ts-btn--small {
    min-height: 40px;
    padding: 8px 12px;
    font-size: 14px;
}

.ts-btn[hidden] {
    display: none;
}

.ts-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 18px;
}

.ts-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 18px auto 0;
    color: var(--ts-faint);
    font-size: 14px;
    text-decoration: none;
}

.ts-back:hover {
    color: var(--ts-cyan);
}

.ts-back svg {
    width: 16px;
    height: 16px;
}

.ts-center {
    text-align: center;
}

/* ---------- Alerts ---------- */
.ts-alerts {
    display: grid;
    gap: 10px;
    margin: 0 0 18px;
    padding: 0;
    list-style: none;
}

.ts-alert {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0;
    padding: 11px 13px;
    border: 1px solid;
    border-radius: var(--ts-radius);
    font-size: 14px;
    line-height: 1.45;
}

.ts-alert > svg {
    flex: none;
    width: 18px;
    height: 18px;
    margin-top: 1px;
}

.ts-alert--success {
    border-color: rgba(0, 255, 127, 0.6);
    background: rgba(0, 255, 127, 0.12);
    color: #b7ffd9;
}

.ts-alert--info {
    border-color: rgba(0, 170, 255, 0.6);
    background: rgba(0, 150, 255, 0.15);
    color: #cdeeff;
}

.ts-alert--warning {
    border-color: rgba(255, 193, 7, 0.65);
    background: rgba(255, 193, 7, 0.12);
    color: #ffe6a0;
}

.ts-alert--error {
    margin-bottom: 18px;
    border-color: rgba(255, 90, 90, 0.7);
    background: rgba(255, 0, 0, 0.16);
    color: #ffd0d0;
}

.ts-alert__list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.ts-alert__list li + li {
    margin-top: 4px;
}

/* ---------- Notices ---------- */
.ts-notice {
    margin-top: 20px;
    padding: 13px 15px;
    border-left: 4px solid var(--ts-sky);
    border-radius: 8px;
    background: rgba(0, 150, 255, 0.18);
    font-size: 13.5px;
}

.ts-notice--gold {
    border-left-color: var(--ts-gold);
    background: rgba(255, 193, 7, 0.1);
}

.ts-notice__title {
    display: flex;
    align-items: center;
    gap: 7px;
    margin: 0 0 8px;
    color: var(--ts-sky);
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.ts-notice--gold .ts-notice__title {
    color: var(--ts-gold);
}

.ts-notice__title svg {
    width: 17px;
    height: 17px;
}

.ts-notice__list {
    display: grid;
    gap: 7px;
    margin: 0;
    padding: 0;
    list-style: none;
    color: rgba(255, 255, 255, 0.9);
}

.ts-notice__list li {
    position: relative;
    padding-left: 16px;
}

.ts-notice__list li::before {
    content: '';
    position: absolute;
    top: 0.62em;
    left: 2px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--ts-sky);
}

.ts-notice--gold .ts-notice__list li::before {
    background: var(--ts-gold);
}

.ts-hl {
    color: var(--ts-sky);
}

.ts-hl-gold {
    color: var(--ts-gold);
}

.ts-note {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin: 14px 0 0;
    padding: 11px 13px;
    border: 1px solid rgba(255, 0, 204, 0.4);
    border-radius: 8px;
    background: rgba(255, 0, 204, 0.1);
    color: #ffd6f5;
    font-size: 13.5px;
}

.ts-note svg {
    flex: none;
    width: 17px;
    height: 17px;
    margin-top: 2px;
}

/* ---------- Application proofs ---------- */
.ts-proofs-title {
    margin: 22px 0 6px;
    color: var(--ts-cyan);
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.6px;
    text-transform: uppercase;
}

.ts-proofs-help {
    margin: 0 0 12px;
    color: var(--ts-faint);
    font-size: 13px;
}

.ts-proof {
    margin: 0 0 14px;
    padding: 16px 16px 2px;
    border: 1px solid rgba(255, 0, 204, 0.25);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.04);
}

.ts-proof__legend {
    padding: 0 6px;
    color: var(--ts-magenta);
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.ts-proof-actions {
    display: flex;
    gap: 10px;
    margin: 0 0 18px;
}

.ts-proof-actions[hidden] {
    display: none;
}

/* ---------- Footer ---------- */
.ts-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 18px;
    color: var(--ts-faint);
    font-size: 13px;
}

.ts-footer img {
    width: 22px;
    height: auto;
}

/* ---------- Focus, motion, small screens ---------- */
a:focus-visible,
button:focus-visible,
.ts-check__input:focus-visible {
    outline: 2px solid var(--ts-cyan);
    outline-offset: 2px;
}

@media (max-width: 420px) {
    body {
        padding: 12px 10px;
    }

    .ts-card {
        padding: 24px 18px;
        border-radius: 16px;
    }

    .ts-brand img {
        max-width: 240px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .ts-stars,
    .ts-card {
        animation: none;
    }

    .ts-btn,
    .ts-input,
    .ts-select,
    .ts-textarea {
        transition: none;
    }

    .ts-btn:hover {
        transform: none;
    }
}

@media (forced-colors: active) {
    .ts-btn,
    .ts-input,
    .ts-select,
    .ts-textarea,
    .ts-card {
        border: 1px solid CanvasText;
    }
}
