/* KADEŞ üye auth — split-screen login / kayıt (görsel birebir) */

.kd-auth {
    --kd-navy: #0b1a3d;
    --kd-navy-2: #122648;
    --kd-navy-3: #1a3260;
    --kd-gold: #d4a017;
    --kd-gold-2: #e8c04a;
    --kd-link: #2f6fed;
    --kd-text: #0b1a3d;
    --kd-muted: #6b7a90;
    --kd-line: #e2e8f0;
    --kd-input-bg: #f8fafc;
    --kd-input-border: #e5eaf0;
    --kd-safe-bg: #f4f6f9;
    font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
    color: var(--kd-text);
    background: #fff;
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(320px, 42%) 1fr;
}

.kd-auth h1,
.kd-auth h2,
.kd-auth h3,
.kd-auth h4,
.kd-auth h5,
.kd-auth h6 {
    color: inherit;
}

.kd-auth a {
    color: inherit;
    text-decoration: none;
}

/* —— Sol panel —— */
.kd-auth-aside {
    position: relative;
    background:
        radial-gradient(ellipse 80% 50% at 50% 72%, rgba(47, 111, 237, 0.22) 0%, transparent 55%),
        linear-gradient(165deg, #071228 0%, var(--kd-navy) 45%, #0e2248 100%);
    color: #fff;
    padding: 2rem 2.25rem 1.75rem;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-height: 100vh;
}

.kd-auth-aside::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    mask-image: linear-gradient(180deg, transparent 0%, #000 30%, #000 70%, transparent 100%);
    pointer-events: none;
    opacity: 0.5;
}

.kd-auth-aside > * {
    position: relative;
    z-index: 1;
}

.kd-auth-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    color: #fff !important;
    margin-bottom: 2rem;
    width: fit-content;
}

.kd-auth-brand-mark {
    width: 2.6rem;
    height: 2.6rem;
    border-radius: 0.6rem;
    background: linear-gradient(145deg, var(--kd-gold-2), var(--kd-gold));
    display: grid;
    place-items: center;
    color: var(--kd-navy);
    box-shadow: 0 8px 20px rgba(212, 160, 23, 0.35);
    flex-shrink: 0;
}

.kd-auth-brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.kd-auth-brand-text strong {
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.kd-auth-brand-text span {
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    opacity: 0.75;
    margin-top: 0.15rem;
}

.kd-auth-aside-title {
    font-size: clamp(1.55rem, 2.4vw, 2rem);
    font-weight: 800;
    line-height: 1.25;
    margin: 0 0 0.75rem;
    max-width: 18ch;
}

.kd-auth-aside-lead {
    margin: 0;
    font-size: 0.92rem;
    line-height: 1.55;
    color: rgba(226, 232, 240, 0.78);
    max-width: 34ch;
}

.kd-auth-visual {
    flex: 1;
    display: grid;
    place-items: center;
    padding: 1.5rem 0;
    min-height: 180px;
}

.kd-auth-visual-inner {
    position: relative;
    width: min(100%, 280px);
    aspect-ratio: 1;
    display: grid;
    place-items: center;
}

.kd-auth-visual-glow {
    position: absolute;
    width: 72%;
    height: 28%;
    bottom: 8%;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 50%;
    background: radial-gradient(ellipse, rgba(47, 111, 237, 0.55) 0%, transparent 70%);
    filter: blur(4px);
}

.kd-auth-visual-ring {
    position: absolute;
    width: 78%;
    height: 78%;
    border-radius: 50%;
    border: 1px solid rgba(47, 111, 237, 0.25);
    box-shadow:
        0 0 0 18px rgba(47, 111, 237, 0.06),
        0 0 40px rgba(47, 111, 237, 0.2);
}

.kd-auth-features {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.9rem;
}

.kd-auth-features li {
    display: grid;
    grid-template-columns: 2.25rem 1fr;
    gap: 0.75rem;
    align-items: start;
}

.kd-auth-features-icon {
    width: 2.4rem;
    height: 2.4rem;
    border-radius: 0.65rem;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(148, 163, 184, 0.22);
    color: #f8fafc;
    display: grid;
    place-items: center;
    flex-shrink: 0;
    box-shadow: 0 6px 16px rgba(2, 8, 23, 0.28);
}

.kd-auth-features-icon svg {
    display: block;
}

.kd-auth-features-icon i {
    font-size: 1.05rem;
    line-height: 1;
}

.kd-auth-features strong {
    display: block;
    font-size: 0.88rem;
    font-weight: 700;
    margin-bottom: 0.1rem;
}

.kd-auth-features span {
    display: block;
    font-size: 0.78rem;
    line-height: 1.4;
    color: rgba(226, 232, 240, 0.65);
}

/* Register stats */
.kd-auth-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
    margin-top: auto;
    padding-top: 0.5rem;
}

.kd-auth-stat {
    text-align: center;
}

.kd-auth-stat-icon {
    width: 2rem;
    height: 2rem;
    margin: 0 auto 0.35rem;
    border-radius: 0.45rem;
    background: rgba(212, 160, 23, 0.14);
    color: var(--kd-gold-2);
    display: grid;
    place-items: center;
}

.kd-auth-stat strong {
    display: block;
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--kd-gold-2);
    line-height: 1.2;
}

.kd-auth-stat span {
    display: block;
    font-size: 0.68rem;
    color: rgba(226, 232, 240, 0.65);
    margin-top: 0.1rem;
}

.kd-auth-aside-cta {
    margin-top: 1.25rem;
    padding: 0.75rem 1rem;
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.88rem;
    color: rgba(226, 232, 240, 0.8);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.kd-auth-aside-cta a {
    color: var(--kd-gold-2) !important;
    font-weight: 700;
    white-space: nowrap;
}

.kd-auth-aside-cta a:hover {
    color: #fff !important;
}

/* —— Sağ panel —— */
.kd-auth-panel {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background: #fff;
    position: relative;
}

.kd-auth-panel-top {
    display: flex;
    justify-content: flex-end;
    padding: 1.25rem 1.75rem 0;
}

.kd-auth-lang {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border: 1px solid var(--kd-line);
    border-radius: 0.55rem;
    padding: 0.4rem 0.65rem;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--kd-muted);
    background: #fff;
    cursor: default;
}

.kd-auth-panel-body {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem 1.75rem 1.25rem;
}

.kd-auth-form {
    width: 100%;
    max-width: 420px;
}

.kd-auth-form--wide {
    max-width: 440px;
}

.kd-auth-form-title {
    font-size: clamp(1.65rem, 2.5vw, 2rem);
    font-weight: 800;
    color: var(--kd-navy);
    margin: 0 0 0.4rem;
    letter-spacing: -0.02em;
}

.kd-auth-form-lead {
    margin: 0 0 1.5rem;
    color: var(--kd-muted);
    font-size: 0.95rem;
}

.kd-auth-field {
    margin-bottom: 0.95rem;
}

.kd-auth-field label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--kd-text);
    margin-bottom: 0.4rem;
}

.kd-auth-input {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    background: var(--kd-input-bg);
    border: 1px solid var(--kd-input-border);
    border-radius: 0.7rem;
    padding: 0 0.85rem;
    min-height: 3rem;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.kd-auth-input:focus-within {
    border-color: #93b4f5;
    box-shadow: 0 0 0 3px rgba(47, 111, 237, 0.12);
    background: #fff;
}

.kd-auth-input > i {
    color: #94a3b8;
    font-size: 1.15rem;
    flex-shrink: 0;
}

.kd-auth-input input {
    flex: 1;
    border: 0;
    background: transparent;
    outline: none;
    font-size: 0.95rem;
    color: var(--kd-text);
    min-width: 0;
    padding: 0.65rem 0;
    font-family: inherit;
}

.kd-auth-input input::placeholder {
    color: #a8b3c4;
}

.kd-auth-eye {
    border: 0;
    background: transparent;
    color: #94a3b8;
    padding: 0.25rem;
    cursor: pointer;
    display: grid;
    place-items: center;
    line-height: 1;
}

.kd-auth-eye:hover {
    color: var(--kd-navy);
}

.kd-auth-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin: 0.25rem 0 1.15rem;
    flex-wrap: wrap;
}

.kd-auth-check {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.85rem;
    color: var(--kd-muted);
    cursor: pointer;
    user-select: none;
}

.kd-auth-check input {
    width: 1rem;
    height: 1rem;
    accent-color: var(--kd-navy);
    margin: 0;
    flex-shrink: 0;
}

.kd-auth-link {
    color: var(--kd-link) !important;
    font-size: 0.85rem;
    font-weight: 600;
}

.kd-auth-link:hover {
    text-decoration: underline !important;
}

.kd-auth-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    min-height: 3rem;
    border-radius: 0.7rem;
    font-size: 0.95rem;
    font-weight: 700;
    font-family: inherit;
    border: 1px solid transparent;
    cursor: pointer;
    transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
}

.kd-auth-btn:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.kd-auth-btn--primary {
    background: var(--kd-navy);
    color: #fff;
    box-shadow: 0 8px 20px rgba(11, 26, 61, 0.22);
}

.kd-auth-btn--primary:hover:not(:disabled) {
    background: #122648;
    color: #fff;
}

.kd-auth-btn--secondary {
    background: #fff;
    color: var(--kd-text);
    border-color: var(--kd-line);
}

.kd-auth-btn--secondary:hover:not(:disabled) {
    background: #f8fafc;
}

.kd-auth-btn + .kd-auth-btn,
.kd-auth-divider + .kd-auth-btn {
    margin-top: 0.75rem;
}

.kd-auth-divider {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin: 1rem 0;
    color: #94a3b8;
    font-size: 0.8rem;
    font-weight: 500;
}

.kd-auth-divider::before,
.kd-auth-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--kd-line);
}

.kd-auth-switch {
    text-align: center;
    margin-top: 1.15rem;
    font-size: 0.9rem;
    color: var(--kd-muted);
}

.kd-auth-switch a {
    color: var(--kd-link) !important;
    font-weight: 700;
}

.kd-auth-switch a:hover {
    text-decoration: underline !important;
}

.kd-auth-agree {
    margin: 0.35rem 0 1.1rem;
    font-size: 0.82rem;
    color: var(--kd-muted);
    line-height: 1.45;
}

.kd-auth-agree a {
    color: var(--kd-link) !important;
    font-weight: 600;
}

.kd-auth-agree a:hover {
    text-decoration: underline !important;
}

.kd-auth-safe {
    margin-top: auto;
    padding: 0.85rem 1.75rem;
    background: var(--kd-safe-bg);
    border-top: 1px solid var(--kd-line);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.78rem;
    color: var(--kd-muted);
    text-align: center;
}

.kd-auth-safe i {
    color: #64748b;
    font-size: 1rem;
}

.kd-auth-alert {
    margin-bottom: 1rem;
    border-radius: 0.65rem;
    padding: 0.75rem 0.9rem;
    font-size: 0.88rem;
}

.kd-auth-alert--error {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}

.kd-auth-alert--info {
    background: #eff6ff;
    color: #1d4ed8;
    border: 1px solid #bfdbfe;
}

/* Compact shell for secondary auth pages */
.kd-auth--compact {
    grid-template-columns: 1fr;
    background: linear-gradient(165deg, #071228 0%, var(--kd-navy) 50%, #0e2248 100%);
    place-items: center;
    padding: 1.5rem;
}

.kd-auth--compact .kd-auth-panel {
    width: 100%;
    max-width: 460px;
    min-height: auto;
    border-radius: 1rem;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
    overflow: hidden;
}

.kd-auth--compact .kd-auth-panel-body {
    padding: 1.75rem 1.5rem 1.25rem;
    align-items: stretch;
}

.kd-auth--compact .kd-auth-form {
    max-width: none;
}

.kd-auth--compact .shys-page-head h1,
.kd-auth--compact .shys-page-head h2 {
    font-size: 1.55rem;
    font-weight: 800;
    color: var(--kd-navy);
    margin-bottom: 0.4rem;
}

.kd-auth--compact .shys-page-head .text-secondary {
    color: var(--kd-muted) !important;
}

.kd-auth--compact .shys-card,
.kd-auth--compact .shys-form {
    background: transparent;
    border: 0;
    box-shadow: none;
    padding: 0;
}

.kd-auth--compact .btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 3rem;
    border-radius: 0.7rem;
    font-weight: 700;
    background: var(--kd-navy);
    border-color: var(--kd-navy);
}

.kd-auth--compact .btn-primary:hover {
    background: #122648;
    border-color: #122648;
}

.kd-auth--compact .btn-link,
.kd-auth--compact a {
    color: var(--kd-link);
    font-weight: 600;
}

.kd-auth--compact .form-control {
    min-height: 3rem;
    border-radius: 0.7rem;
    background: var(--kd-input-bg);
    border-color: var(--kd-input-border);
}

.kd-auth--compact .kd-auth-brand-bar {
    display: flex;
    justify-content: center;
    padding: 1.25rem 1rem 0;
}

.kd-auth--compact .kd-auth-brand {
    margin-bottom: 0;
}

@media (max-width: 991.98px) {
    .kd-auth {
        grid-template-columns: 1fr;
    }

    .kd-auth-aside {
        min-height: auto;
        padding: 1.5rem 1.25rem 1.25rem;
    }

    .kd-auth-aside-title {
        max-width: none;
        font-size: 1.45rem;
    }

    .kd-auth-visual {
        display: none;
    }

    .kd-auth-features {
        margin-top: 1.25rem;
    }

    .kd-auth-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.85rem;
    }

    .kd-auth-panel {
        min-height: auto;
    }

    .kd-auth-panel-body {
        padding: 1.25rem 1.25rem 1rem;
        align-items: stretch;
    }

    .kd-auth-safe {
        padding: 0.85rem 1.25rem;
    }
}

@media (max-width: 575.98px) {
    .kd-auth-stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .kd-auth-aside-cta {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Motion */
@keyframes kd-auth-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

@keyframes kd-auth-pulse {
    0%, 100% { opacity: 0.55; transform: translateX(-50%) scale(1); }
    50% { opacity: 0.9; transform: translateX(-50%) scale(1.05); }
}

.kd-auth-visual-float {
    animation: kd-auth-float 4.5s ease-in-out infinite;
    position: relative;
    z-index: 2;
}

.kd-auth-visual-glow {
    animation: kd-auth-pulse 3.5s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
    .kd-auth-visual-float,
    .kd-auth-visual-glow {
        animation: none;
    }
}
