/* ==========================================
   SIGNUP.PHP - ishowplay AI Platform
   Design System: Matching index_v2.css
   Version: 3.0.0
   ========================================== */

/* CSS Variables - Aligned with index_v2.css */
:root {
    /* Light Theme - Matching index_v2.css exactly */
    --signup-background: #f6f8ff;
    --signup-surface: rgba(255, 255, 255, 0.92);
    --signup-surface-strong: rgba(255, 255, 255, 0.97);
    --signup-border: rgba(120, 138, 255, 0.22);
    --signup-border-strong: rgba(120, 138, 255, 0.32);
    --signup-shadow: 0 48px 120px rgba(133, 144, 255, 0.16);
    --signup-text-primary: #111633;
    --signup-text-secondary: rgba(22, 29, 60, 0.68);
    --signup-text-muted: rgba(22, 29, 60, 0.4);
    --signup-accent: #4e6dff;
    --signup-accent-soft: rgba(78, 109, 255, 0.15);
    --signup-teal: #39cdc2;
    --signup-amber: #ffb347;
    --signup-white: #ffffff;
    --signup-success: #34c759;
    --signup-warning: #ff9500;
    --signup-error: #ff3b30;
}

/* Dark Theme - Matching index_v2.css exactly */
[data-theme="dark"] {
    --signup-background: #030510;
    --signup-surface: rgba(10, 18, 36, 0.88);
    --signup-surface-strong: rgba(14, 26, 50, 0.94);
    --signup-border: rgba(132, 156, 255, 0.34);
    --signup-border-strong: rgba(132, 156, 255, 0.44);
    --signup-shadow: 0 70px 170px rgba(2, 4, 10, 0.75);
    --signup-text-primary: #f3f7ff;
    --signup-text-secondary: rgba(199, 211, 255, 0.86);
    --signup-text-muted: rgba(160, 178, 226, 0.7);
    --signup-accent: #9bb4ff;
    --signup-accent-soft: rgba(155, 180, 255, 0.24);
    --signup-teal: #39cdc2;
    --signup-amber: #ffb347;
    --signup-white: #ffffff;
    --signup-success: #32d74b;
    --signup-warning: #ff9f0a;
    --signup-error: #ff453a;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Helvetica Neue", "PingFang TC", "Microsoft JhengHei", sans-serif;
    background: var(--signup-background);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--signup-text-primary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background 0.6s ease, color 0.3s ease;
    overflow-x: hidden;
}

/* Note: Signup page is standalone - no sidebar or app container needed */

/* ==========================================
   TOP NAVIGATION BAR (ChatGPT/Claude style)
   ========================================== */

.signup-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 72px;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-bottom: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    z-index: 100;
    box-shadow: none;
    transition: all 0.3s ease;
}

.signup-nav__logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.signup-nav__logo:hover {
    opacity: 0.8;
}

/* Logo image styling (matching header.php) */
.signup-nav__logo-full {
    height: 36px;
    width: auto;
    object-fit: contain;
    display: block;
}

.signup-nav__logo-icon {
    display: none;
}

[data-theme="dark"] .signup-nav__logo-full {
    filter: brightness(1.2);
}

.signup-nav__actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Language Selector - Custom Dropdown */
.language-selector {
    position: relative;
    display: inline-block;
}

.language-selector .lang-button {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 10px 18px;
    border-radius: 14px;
    border: 1px solid rgba(142, 169, 255, 0.28);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.26), rgba(244, 248, 255, 0.18));
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    color: var(--signup-text-primary);
    cursor: pointer;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border 0.25s ease, background 0.25s ease;
    font-size: 14px;
    font-weight: 500;
}

.language-selector .lang-button:hover,
.language-selector.active .lang-button {
    transform: translateY(-1px);
    border-color: rgba(142, 169, 255, 0.45);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.32), rgba(232, 240, 255, 0.26));
    box-shadow: 0 14px 28px rgba(79, 110, 255, 0.18);
}

.language-selector .lang-name {
    font-weight: 500;
}

.language-selector .dropdown-icon {
    transition: transform 0.3s ease;
}

.language-selector.active .dropdown-icon {
    transform: rotate(180deg);
}

.language-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: var(--signup-surface);
    border: 1px solid var(--signup-border);
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
    z-index: 99999;
    min-width: 180px;
    overflow: hidden;
    display: block;
    pointer-events: none;
}

.language-selector.active .language-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.language-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    color: var(--signup-text-primary);
}

.language-option:hover {
    background: rgba(142, 169, 255, 0.12);
}

.language-option.active {
    background: rgba(142, 169, 255, 0.18);
    color: var(--signup-accent);
    font-weight: 600;
}

/* Dark Mode Support */
html[data-theme="dark"] .language-selector .lang-button {
    border-color: rgba(108, 134, 255, 0.32);
    background: linear-gradient(135deg, rgba(24, 32, 60, 0.72), rgba(35, 48, 82, 0.68));
    color: #dbe4ff;
}

html[data-theme="dark"] .language-selector .lang-button:hover,
html[data-theme="dark"] .language-selector.active .lang-button {
    border-color: rgba(126, 156, 255, 0.48);
    background: linear-gradient(135deg, rgba(37, 52, 92, 0.88), rgba(51, 65, 110, 0.84));
    box-shadow: 0 20px 36px rgba(25, 42, 90, 0.45);
}

html[data-theme="dark"] .language-dropdown {
    background: rgba(17, 22, 51, 0.95);
    border-color: rgba(108, 134, 255, 0.25);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

html[data-theme="dark"] .language-option:hover {
    background: rgba(114, 142, 255, 0.2);
}

html[data-theme="dark"] .language-option.active {
    background: rgba(114, 142, 255, 0.28);
    color: #e7ecff;
}

/* Theme toggle section (from header.php) */
.index2-theme-switch-nav {
    display: inline-flex;
    align-items: center;
    margin-right: 12px;
}

/* Theme toggle button - Matching header.php exactly */
.theme-toggle-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 14px;
    padding: 12px 22px 12px 68px;
    border-radius: 999px;
    border: 1px solid rgba(142, 169, 255, 0.3);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(231, 240, 255, 0.9));
    box-shadow: 0 24px 50px rgba(120, 146, 255, 0.18);
    color: var(--signup-text-primary);
    font-size: 0.92rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease, background 0.35s ease;
    overflow: hidden;
}

.theme-toggle-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 32px 60px rgba(120, 146, 255, 0.2);
}

.theme-toggle-btn:focus-visible {
    outline: none;
    box-shadow: 0 0 0 4px rgba(120, 146, 255, 0.25), 0 24px 50px rgba(120, 146, 255, 0.18);
}

.theme-toggle-btn .toggle-handle {
    position: absolute;
    left: 6px;
    top: 50%;
    width: 46px;
    height: 46px;
    border-radius: 999px;
    background: linear-gradient(135deg, #7aa5ff, #5be6d4);
    box-shadow: 0 18px 30px rgba(90, 140, 255, 0.35);
    transform: translateY(-50%);
    transition: transform 0.4s cubic-bezier(0.25, 0.1, 0.25, 1), background 0.3s ease;
}

.theme-toggle-btn .toggle-icon {
    font-size: 1.15rem;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.theme-toggle-btn .toggle-icon--moon {
    opacity: 0;
    transform: translateY(6px);
}

.theme-toggle-btn .toggle-text {
    display: flex;
    flex-direction: column;
    text-align: left;
    line-height: 1.2;
}

.theme-toggle-btn .toggle-text strong {
    font-size: 0.92rem;
    font-weight: 600;
    color: inherit;
}

.theme-toggle-btn .toggle-text span {
    font-size: 0.72rem;
    font-weight: 500;
    color: rgba(22, 29, 60, 0.55);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

/* Dark mode state for theme toggle */
.theme-toggle-btn.is-dark {
    border-color: rgba(108, 134, 255, 0.38);
    background: linear-gradient(140deg, rgba(17, 27, 58, 0.96), rgba(31, 46, 80, 0.92));
    box-shadow: 0 26px 68px rgba(12, 20, 46, 0.55);
    color: #e9eeff;
}

.theme-toggle-btn.is-dark .toggle-handle {
    transform: translate(56px, -50%);
    background: linear-gradient(135deg, #3f62ff, #32d7c9);
    box-shadow: 0 20px 36px rgba(37, 73, 200, 0.45);
}

.theme-toggle-btn.is-dark .toggle-icon--sun {
    opacity: 0;
    transform: translateY(-6px);
}

.theme-toggle-btn.is-dark .toggle-icon--moon {
    opacity: 1;
    transform: translateY(0);
}

.theme-toggle-btn.is-dark .toggle-text span {
    color: rgba(204, 216, 255, 0.72);
}

/* Dark theme styles */
html[data-theme="dark"] .theme-toggle-btn {
    border-color: rgba(108, 134, 255, 0.38);
    background: linear-gradient(140deg, rgba(17, 27, 58, 0.96), rgba(31, 46, 80, 0.92));
    box-shadow: 0 26px 68px rgba(12, 20, 46, 0.55);
    color: #e9eeff;
}

html[data-theme="dark"] .theme-toggle-btn .toggle-handle {
    transform: translate(56px, -50%);
    background: linear-gradient(135deg, #3f62ff, #32d7c9);
    box-shadow: 0 20px 36px rgba(37, 73, 200, 0.45);
}

html[data-theme="dark"] .theme-toggle-btn .toggle-icon--sun {
    opacity: 0;
    transform: translateY(-6px);
}

html[data-theme="dark"] .theme-toggle-btn .toggle-icon--moon {
    opacity: 1;
    transform: translateY(0);
}

html[data-theme="dark"] .theme-toggle-btn .toggle-text span {
    color: rgba(204, 216, 255, 0.72);
}

/* Navigation divider (from header.php) */
.nav-divider {
    width: 1px;
    height: 24px;
    background: var(--signup-border);
    opacity: 0.6;
}

/* Login button - matching header.php's btn-login exactly */
.btn-login {
    padding: 10px 22px;
    border-radius: 14px;
    font-size: 14px;
    font-weight: 600;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border 0.25s ease, background 0.25s ease;
    cursor: pointer;
    border: none;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1.2;
    letter-spacing: 0.03em;
    background: linear-gradient(135deg, #6f8dff 0%, #45d0c2 100%);
    color: #ffffff;
    box-shadow: 0 16px 32px rgba(80, 112, 255, 0.35);
}

.btn-login:hover {
    transform: translateY(-1px);
    box-shadow: 0 22px 44px rgba(80, 112, 255, 0.42);
}

[data-theme="dark"] .btn-login {
    background: linear-gradient(135deg, #5a74ff 0%, #29c5bb 100%);
    box-shadow: 0 20px 42px rgba(37, 52, 120, 0.55);
}

/* Responsive navigation */
@media (max-width: 1024px) {
    .theme-toggle-btn .toggle-text span {
        display: none;
    }
    .theme-toggle-btn {
        padding: 12px 20px 12px 64px;
    }
}

@media (max-width: 768px) {
    .signup-nav {
        padding: 10px 15px;
        height: 72px;
    }

    .signup-nav__logo-full {
        display: none;
    }

    .signup-nav__logo-icon {
        display: block;
        width: 40px;
        height: 40px;
    }

    .signup-nav__actions {
        gap: 8px;
    }

    .index2-theme-switch-nav {
        margin-right: 8px;
    }

    /* Mobile: Convert theme toggle to circular icon-only button */
    .theme-toggle-btn {
        width: 56px;
        height: 56px;
        padding: 0;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        position: relative;
    }

    .theme-toggle-btn .toggle-handle {
        display: none;
    }

    .theme-toggle-btn .toggle-text {
        display: none;
    }

    .theme-toggle-btn .toggle-icon {
        position: static;
        font-size: 1.5rem;
        opacity: 1 !important;
        transform: none !important;
    }

    /* Light Mode: Show sun only */
    .theme-toggle-btn .toggle-icon--moon {
        display: none;
    }

    /* Dark Mode: Show moon only */
    .theme-toggle-btn.is-dark .toggle-icon--sun,
    html[data-theme="dark"] .theme-toggle-btn .toggle-icon--sun {
        display: none;
    }

    .theme-toggle-btn.is-dark .toggle-icon--moon,
    html[data-theme="dark"] .theme-toggle-btn .toggle-icon--moon {
        display: block;
    }

    .language-selector .lang-button {
        padding: 8px 10px;
        font-size: 13px;
    }

    .btn-login {
        padding: 8px 16px;
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .signup-nav {
        padding: 0 16px;
    }

    .signup-nav__logo-img {
        height: 28px;
    }

    .theme-toggle-btn {
        width: 50px;
        height: 50px;
    }

    .theme-toggle-btn .toggle-icon {
        font-size: 1.3rem;
    }

    .language-selector .lang-button {
        padding: 6px 8px;
        font-size: 12px;
    }

    .btn-login {
        padding: 6px 12px;
        font-size: 12px;
    }

    .nav-divider {
        height: 20px;
    }
}

/* ==========================================
   BACKGROUND SYSTEM - Matching index_v2.css
   ========================================== */

.signup-backdrop {
    position: fixed;
    inset: 0;
    z-index: -10;
    overflow: hidden;
    contain: layout style paint;
    background: radial-gradient(circle at 10% 20%, rgba(102, 140, 255, 0.35), transparent 55%),
                radial-gradient(circle at 85% 28%, rgba(81, 236, 223, 0.32), transparent 52%),
                radial-gradient(circle at 46% 82%, rgba(255, 176, 104, 0.26), transparent 62%),
                linear-gradient(130deg, #040712 0%, #071331 55%, #020513 100%);
    mask-image: radial-gradient(150% 180% at 50% 40%, rgba(0, 0, 0, 0.96) 0%, rgba(0, 0, 0, 0.78) 62%, rgba(0, 0, 0, 0.18) 86%, rgba(0, 0, 0, 0) 100%);
    -webkit-mask-image: radial-gradient(150% 180% at 50% 40%, rgba(0, 0, 0, 0.96) 0%, rgba(0, 0, 0, 0.78) 62%, rgba(0, 0, 0, 0.18) 86%, rgba(0, 0, 0, 0) 100%);
}

.signup-backdrop::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 30%, rgba(155, 180, 255, 0.25) 0%, rgba(12, 20, 40, 0) 55%),
        radial-gradient(circle at 78% 68%, rgba(114, 250, 238, 0.18) 0%, rgba(8, 15, 30, 0) 60%);
    opacity: 0.55;
    mix-blend-mode: screen;
    animation: signup-aurora-sweep 28s ease-in-out infinite;
    will-change: transform, opacity;
}

/* Light mode backdrop */
html:not([data-theme="dark"]) .signup-backdrop {
    background: radial-gradient(circle at 12% 18%, rgba(127, 168, 255, 0.35), transparent 55%),
                radial-gradient(circle at 82% 22%, rgba(137, 234, 226, 0.32), transparent 55%),
                radial-gradient(circle at 45% 80%, rgba(255, 196, 135, 0.25), transparent 60%),
                linear-gradient(135deg, #f7f9ff 0%, #ecf2ff 45%, #f6fbff 100%);
}

html:not([data-theme="dark"]) .signup-backdrop::before {
    background:
        radial-gradient(circle at 24% 32%, rgba(101, 143, 255, 0.32) 0%, rgba(255, 255, 255, 0) 58%),
        radial-gradient(circle at 78% 64%, rgba(132, 236, 226, 0.25) 0%, rgba(255, 255, 255, 0) 62%);
    opacity: 0.75;
}

/* Glow effects */
.signup-backdrop__glow {
    position: absolute;
    width: 520px;
    height: 520px;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.65;
    animation: signup-glow-drift 22s ease-in-out infinite;
    will-change: transform;
}

.signup-backdrop__glow--primary {
    top: -80px;
    right: 15%;
    background: #7fa1ff;
    animation-delay: 0s;
}

.signup-backdrop__glow--secondary {
    bottom: -120px;
    left: 12%;
    background: #54f0e4;
    animation-delay: 6s;
}

/* Grid overlay */
.signup-backdrop__grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.14) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.14) 1px, transparent 1px);
    background-size: 160px 160px;
    opacity: 0.4;
    mask-image: radial-gradient(circle at center, rgba(255, 255, 255, 0.9), transparent 70%);
}

[data-theme="dark"] .signup-backdrop__grid {
    background-image:
        linear-gradient(rgba(107, 114, 128, 0.2) 1px, transparent 1px),
        linear-gradient(90deg, rgba(107, 114, 128, 0.2) 1px, transparent 1px);
}

/* Particles */
.signup-backdrop__particles {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.signup-backdrop__particles span {
    position: absolute;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: rgba(142, 169, 255, 0.55);
    box-shadow: 0 0 12px rgba(120, 154, 255, 0.55);
    animation: signup-particles-float 18s linear infinite;
}

.signup-backdrop__particles span:nth-child(1) {
    top: 15%; left: 20%;
    animation-duration: 24s;
}

.signup-backdrop__particles span:nth-child(2) {
    top: 75%; left: 80%;
    animation-duration: 22s;
    background: rgba(96, 246, 232, 0.6);
    box-shadow: 0 0 14px rgba(96, 246, 232, 0.55);
}

.signup-backdrop__particles span:nth-child(3) {
    top: 45%; left: 60%;
    animation-duration: 19s;
}

.signup-backdrop__particles span:nth-child(4) {
    top: 90%; left: 10%;
    animation-duration: 26s;
    background: rgba(255, 195, 120, 0.6);
    box-shadow: 0 0 14px rgba(255, 195, 120, 0.55);
}

.signup-backdrop__particles span:nth-child(5) {
    top: 10%; left: 90%;
    animation-duration: 20s;
}

.signup-backdrop__particles span:nth-child(6) {
    top: 60%; left: 30%;
    animation-duration: 18s;
    background: rgba(255, 255, 255, 0.78);
    box-shadow: 0 0 14px rgba(255, 255, 255, 0.65);
}

/* Animations */
@keyframes signup-aurora-sweep {
    0% {
        transform: rotate(0deg) scale(1);
        opacity: 0.45;
    }
    40% {
        transform: rotate(12deg) scale(1.05);
        opacity: 0.7;
    }
    70% {
        transform: rotate(-8deg) scale(1.02);
        opacity: 0.55;
    }
    100% {
        transform: rotate(0deg) scale(1);
        opacity: 0.45;
    }
}

@keyframes signup-glow-drift {
    0%, 100% {
        transform: translate3d(0, 0, 0) scale(1);
    }
    50% {
        transform: translate3d(18px, -24px, 0) scale(1.05);
    }
}

@keyframes signup-particles-float {
    0% {
        transform: translate3d(0, 0, 0) scale(1);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    60% {
        opacity: 1;
    }
    100% {
        transform: translate3d(0, -120px, 0) scale(1.4);
        opacity: 0;
    }
}

/* ==========================================
   SIGNUP CONTAINER & CARD
   ========================================== */

.signup-container {
    width: 100%;
    max-width: 520px;
    padding: 100px 20px 20px; /* Top padding for nav bar */
    position: relative;
    z-index: 1;
    animation: signup-container-enter 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes signup-container-enter {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.signup-card {
    background: var(--signup-surface);
    backdrop-filter: blur(28px) saturate(180%);
    -webkit-backdrop-filter: blur(28px) saturate(180%);
    border-radius: 36px;
    padding: 52px;
    box-shadow: var(--signup-shadow);
    border: 1px solid var(--signup-border);
    position: relative;
    overflow: hidden;
}

/* Card glow effect */
.signup-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 78% 18%, rgba(110, 150, 255, 0.2), transparent 60%);
    pointer-events: none;
    opacity: 0.6;
    z-index: 0;
}

.signup-card::after {
    content: "";
    position: absolute;
    inset: -20%;
    background: radial-gradient(circle at top right, rgba(142, 169, 255, 0.22), transparent 58%);
    opacity: 0.6;
    pointer-events: none;
    transition: opacity 0.45s ease;
    animation: signup-card-glow 20s ease-in-out infinite;
}

@keyframes signup-card-glow {
    0%, 100% {
        transform: translate3d(-4%, -3%, 0) scale(1);
        opacity: 0.5;
    }
    50% {
        transform: translate3d(4%, 6%, 0) scale(1.05);
        opacity: 0.75;
    }
}

.signup-card > * {
    position: relative;
    z-index: 1;
}

/* ==========================================
   LOGO SECTION
   ========================================== */

.logo-section {
    text-align: center;
    margin-bottom: 36px;
}

/* Logo moved to top navigation bar */

h1 {
    font-size: clamp(2.2rem, 3vw, 2.8rem);
    font-weight: 700;
    color: var(--signup-text-primary);
    margin-bottom: 12px;
    letter-spacing: -0.015em;
    line-height: 1.2;
}

.subtitle {
    font-size: 1.05rem;
    color: var(--signup-text-secondary);
    font-weight: 400;
    line-height: 1.6;
}

/* ==========================================
   FORM STYLES
   ========================================== */

.form-group {
    margin-bottom: 24px;
}

.form-label {
    display: block;
    margin-bottom: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--signup-text-primary);
    letter-spacing: -0.01em;
}

.input-wrapper {
    position: relative;
}

input[type="email"],
input[type="password"],
input[type="tel"],
input[type="text"],
select {
    width: 100%;
    padding: 18px 20px;
    font-size: 1.05rem;
    border: 1px solid var(--signup-border);
    border-radius: 18px;
    background: rgba(23, 36, 74, 0.4);
    color: var(--signup-text-primary);
    transition: all 0.3s cubic-bezier(0.21, 0.8, 0.32, 1);
    font-family: inherit;
    -webkit-appearance: none;
}

/* Light mode input background */
html:not([data-theme="dark"]) input[type="email"],
html:not([data-theme="dark"]) input[type="password"],
html:not([data-theme="dark"]) input[type="tel"],
html:not([data-theme="dark"]) input[type="text"],
html:not([data-theme="dark"]) select {
    background: rgba(244, 247, 255, 0.92);
}

input:focus,
select:focus {
    outline: none;
    border-color: var(--signup-accent);
    background: var(--signup-surface-strong);
    box-shadow: 0 0 0 4px var(--signup-accent-soft),
                0 18px 44px rgba(63, 109, 255, 0.18);
    transform: translateY(-2px);
}

input::placeholder {
    color: var(--signup-text-muted);
}

/* Password Toggle with Animation */
.password-toggle {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: var(--signup-text-secondary);
    transition: all 0.3s ease;
    padding: 4px;
    border-radius: 8px;
}

.password-toggle:hover {
    color: var(--signup-accent);
    background: var(--signup-accent-soft);
    transform: translateY(-50%) scale(1.1);
}

/* Phone Input Group */
.phone-input-group {
    display: flex;
    gap: 14px;
}

.country-code-select {
    width: 160px;
    flex-shrink: 0;
}

/* Verification Group with Enhanced Button */
.verification-group {
    display: flex;
    gap: 14px;
    align-items: stretch;
}

.verification-input {
    flex: 1;
}

.btn-send-code {
    padding: 18px 28px;
    font-size: 1rem;
    font-weight: 600;
    color: var(--signup-white);
    background: linear-gradient(135deg, rgba(57, 205, 194, 0.95), rgba(39, 195, 184, 0.9));
    border: none;
    border-radius: 18px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.21, 0.8, 0.32, 1);
    font-family: inherit;
    white-space: nowrap;
    position: relative;
    overflow: hidden;
    box-shadow: 0 18px 44px rgba(57, 205, 194, 0.24);
}

.btn-send-code::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent, rgba(255, 255, 255, 0.2));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.btn-send-code:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 24px 60px rgba(57, 205, 194, 0.35);
}

.btn-send-code:hover:not(:disabled)::before {
    opacity: 1;
}

.btn-send-code:active {
    transform: translateY(-1px);
}

.btn-send-code:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: rgba(57, 205, 194, 0.5);
}

/* Countdown animation for send code button */
.btn-send-code.countdown {
    animation: pulse-teal 1s ease-in-out infinite;
}

@keyframes pulse-teal {
    0%, 100% {
        box-shadow: 0 18px 44px rgba(57, 205, 194, 0.24);
    }
    50% {
        box-shadow: 0 18px 44px rgba(57, 205, 194, 0.4);
    }
}

/* Light Mode Send Code Button Optimization */
html:not([data-theme="dark"]) .btn-send-code {
    background: linear-gradient(135deg, #39cdc2, #27c3b8);
    color: #ffffff;
    box-shadow: 0 8px 24px rgba(57, 205, 194, 0.3);
}

html:not([data-theme="dark"]) .btn-send-code:hover:not(:disabled) {
    box-shadow: 0 14px 40px rgba(57, 205, 194, 0.4);
}

/* ==========================================
   PASSWORD STRENGTH INDICATOR - Enhanced
   ========================================== */

.password-strength {
    margin-top: 16px;
    padding: 16px;
    background: rgba(28, 43, 86, 0.85);
    border-radius: 16px;
    border: 1px solid rgba(142, 169, 255, 0.18);
    transition: all 0.3s ease;
}

html:not([data-theme="dark"]) .password-strength {
    background: rgba(230, 239, 255, 0.88);
    border-color: rgba(130, 148, 255, 0.2);
}

.strength-meter {
    height: 6px;
    background: rgba(142, 169, 255, 0.15);
    border-radius: 3px;
    margin-bottom: 14px;
    overflow: hidden;
    position: relative;
}

.strength-meter::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: shimmer 2s linear infinite;
    opacity: 0.5;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

.strength-meter-fill {
    height: 100%;
    transition: all 0.5s cubic-bezier(0.21, 0.8, 0.32, 1);
    border-radius: 3px;
    position: relative;
    z-index: 1;
}

.password-strength.weak .strength-meter-fill {
    background: linear-gradient(135deg, var(--signup-error), rgba(255, 69, 58, 0.8));
    width: 25%;
    box-shadow: 0 0 20px rgba(255, 69, 58, 0.4);
}

.password-strength.medium .strength-meter-fill {
    background: linear-gradient(135deg, var(--signup-warning), rgba(255, 159, 10, 0.8));
    width: 50%;
    box-shadow: 0 0 20px rgba(255, 159, 10, 0.4);
}

.password-strength.strong .strength-meter-fill {
    background: linear-gradient(135deg, var(--signup-success), rgba(50, 215, 75, 0.8));
    width: 75%;
    box-shadow: 0 0 20px rgba(50, 215, 75, 0.4);
}

.password-strength.very-strong .strength-meter-fill {
    background: linear-gradient(135deg, var(--signup-success), rgba(50, 215, 75, 0.9));
    width: 100%;
    box-shadow: 0 0 25px rgba(50, 215, 75, 0.5);
    animation: pulse-success 2s ease-in-out infinite;
}

@keyframes pulse-success {
    0%, 100% {
        box-shadow: 0 0 25px rgba(50, 215, 75, 0.5);
    }
    50% {
        box-shadow: 0 0 35px rgba(50, 215, 75, 0.7);
    }
}

.strength-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.strength-text {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--signup-text-primary);
}

.strength-level {
    font-size: 0.85rem;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 8px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.password-strength.weak .strength-level {
    background: rgba(255, 59, 48, 0.15);
    color: var(--signup-error);
}

.password-strength.medium .strength-level {
    background: rgba(255, 149, 0, 0.15);
    color: var(--signup-warning);
}

.password-strength.strong .strength-level,
.password-strength.very-strong .strength-level {
    background: rgba(52, 199, 89, 0.15);
    color: var(--signup-success);
}

.requirements {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 12px;
}

.requirement-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--signup-text-muted);
    transition: all 0.3s ease;
}

.requirement-item.valid {
    color: var(--signup-success);
    transform: translateX(3px);
}

.requirement-item.valid .requirement-icon {
    animation: checkmark-pop 0.3s ease;
}

@keyframes checkmark-pop {
    0% {
        transform: scale(0);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

.requirement-icon {
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ==========================================
   TERMS & PRIMARY BUTTON
   ========================================== */

.terms-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin: 28px 0;
}

.terms-checkbox {
    width: 22px;
    height: 22px;
    margin-top: 2px;
    cursor: pointer;
    accent-color: var(--signup-accent);
}

.terms-label {
    font-size: 0.9rem;
    color: var(--signup-text-secondary);
    line-height: 1.6;
    cursor: pointer;
}

.terms-label a {
    color: var(--signup-accent);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
    position: relative;
}

.terms-label a::after {
    content: "";
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--signup-accent);
    transition: width 0.3s ease;
}

.terms-label a:hover::after {
    width: 100%;
}

/* Primary Submit Button - Matching vision-card__action style */
.btn-primary {
    width: 100%;
    padding: 18px;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--signup-white);
    background: linear-gradient(135deg, rgba(63, 109, 255, 0.95), rgba(87, 218, 204, 0.9));
    border: none;
    border-radius: 18px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.21, 0.8, 0.32, 1);
    font-family: inherit;
    position: relative;
    overflow: hidden;
    box-shadow: 0 18px 44px rgba(63, 109, 255, 0.24);
}

.btn-primary::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent, rgba(255, 255, 255, 0.2));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 36px 80px rgba(63, 109, 255, 0.35);
}

.btn-primary:hover:not(:disabled)::before {
    opacity: 1;
}

.btn-primary:active {
    transform: translateY(-1px);
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: linear-gradient(135deg, rgba(63, 109, 255, 0.5), rgba(87, 218, 204, 0.5));
}

.btn-primary.loading {
    color: transparent;
    pointer-events: none;
}

.btn-primary.loading::after {
    content: '';
    position: absolute;
    width: 22px;
    height: 22px;
    top: 50%;
    left: 50%;
    margin-left: -11px;
    margin-top: -11px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Light Mode Button Optimization */
html:not([data-theme="dark"]) .btn-primary {
    background: linear-gradient(135deg, #4e6dff, #39cdc2);
    color: #ffffff;
    box-shadow: 0 10px 30px rgba(78, 109, 255, 0.28);
}

html:not([data-theme="dark"]) .btn-primary:hover:not(:disabled) {
    box-shadow: 0 16px 48px rgba(78, 109, 255, 0.38);
}

/* ==========================================
   DIVIDER & SOCIAL BUTTONS
   ========================================== */

.divider {
    text-align: center;
    margin: 36px 0;
    position: relative;
}

.divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--signup-border), transparent);
}

.divider span {
    background: var(--signup-surface);
    padding: 0 24px;
    font-size: 0.9rem;
    color: var(--signup-text-secondary);
    position: relative;
    font-weight: 500;
}

.social-buttons {
    display: flex;
    gap: 14px;
    margin-bottom: 36px;
}

.btn-social {
    flex: 1;
    padding: 16px;
    font-size: 0.95rem;
    font-weight: 600;
    border: 1px solid var(--signup-border);
    border-radius: 16px;
    background: rgba(28, 43, 86, 0.85);
    color: var(--signup-text-primary);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.21, 0.8, 0.32, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-family: inherit;
    position: relative;
    overflow: hidden;
}

html:not([data-theme="dark"]) .btn-social {
    background: rgba(237, 242, 255, 0.98);
    border-color: rgba(124, 142, 255, 0.4);
    box-shadow: 0 4px 12px rgba(124, 142, 255, 0.12);
}

.btn-social::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent, rgba(142, 169, 255, 0.1));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.btn-social:hover {
    transform: translateY(-3px);
    box-shadow: 0 18px 44px rgba(140, 158, 255, 0.18);
    border-color: var(--signup-accent);
}

.btn-social:hover::before {
    opacity: 1;
}

.btn-social:active {
    transform: translateY(-1px);
}

.social-icon {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
}

/* Apple icon - Black in Light Mode */
[data-theme="light"] .btn-apple .social-icon,
html:not([data-theme="dark"]) .btn-apple .social-icon {
    filter: brightness(0);
}

/* Apple Sign In Button - Special Style */
.btn-apple {
    background: var(--signup-text-primary);
    color: var(--signup-surface);
    border-color: var(--signup-text-primary);
}

.btn-apple:hover {
    background: var(--signup-accent);
    border-color: var(--signup-accent);
    color: var(--signup-white);
}

/* Dark Mode Apple Button - Dark background with white icon */
[data-theme="dark"] .btn-apple {
    background: rgba(28, 43, 86, 0.85);
    color: #ffffff;
    border-color: rgba(132, 156, 255, 0.3);
}

[data-theme="dark"] .btn-apple .social-icon {
    filter: brightness(0) invert(1);
}

/* ==========================================
   FOOTER SECTION
   ========================================== */

.register-section {
    text-align: center;
    margin-top: 28px;
    padding-top: 28px;
    border-top: 1px solid var(--signup-border);
    font-size: 0.95rem;
    color: var(--signup-text-secondary);
}

.register-section a {
    color: var(--signup-accent);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
    position: relative;
}

.register-section a::after {
    content: "";
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--signup-accent);
    transition: width 0.3s ease;
}

.register-section a:hover::after {
    width: 100%;
}

/* Theme toggle and language selector moved to top navigation */

/* ==========================================
   NOTIFICATION TOAST - Enhanced
   ========================================== */

.notification {
    position: fixed;
    top: 90px;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    background: var(--signup-surface);
    backdrop-filter: blur(28px);
    border: 1px solid var(--signup-border);
    padding: 18px 28px;
    border-radius: 16px;
    box-shadow: var(--signup-shadow);
    display: flex;
    align-items: center;
    gap: 14px;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.21, 0.8, 0.32, 1);
    z-index: 1000;
}

.notification.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
    animation: notification-bounce 0.5s ease;
}

@keyframes notification-bounce {
    0% {
        transform: translateX(-50%) translateY(-20px);
    }
    50% {
        transform: translateX(-50%) translateY(5px);
    }
    100% {
        transform: translateX(-50%) translateY(0);
    }
}

.notification.success {
    border-color: var(--signup-success);
    background: linear-gradient(135deg, rgba(52, 199, 89, 0.1), transparent);
}

.notification.error {
    border-color: var(--signup-error);
    background: linear-gradient(135deg, rgba(255, 59, 48, 0.1), transparent);
}

.notification-icon {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
}

.notification.success .notification-icon {
    color: var(--signup-success);
    animation: checkmark-draw 0.5s ease;
}

.notification.error .notification-icon {
    color: var(--signup-error);
    animation: error-shake 0.5s ease;
}

@keyframes checkmark-draw {
    from {
        transform: scale(0) rotate(-45deg);
    }
    to {
        transform: scale(1) rotate(0);
    }
}

@keyframes error-shake {
    0%, 100% {
        transform: translateX(0);
    }
    25% {
        transform: translateX(-5px);
    }
    75% {
        transform: translateX(5px);
    }
}

.notification-message {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--signup-text-primary);
}

/* ==========================================
   RESPONSIVE DESIGN
   ========================================== */

@media (max-width: 768px) {
    .signup-container {
        padding: 76px 16px 16px; /* Adjust for smaller nav */
    }
    
    .signup-card {
        padding: 36px 28px;
        border-radius: 28px;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .subtitle {
        font-size: 0.95rem;
    }
    
    .phone-input-group {
        flex-direction: column;
    }
    
    .country-code-select {
        width: 100%;
    }
    
    .verification-group {
        flex-direction: column;
    }
    
    .btn-send-code {
        width: 100%;
    }
    
    .social-buttons {
        flex-direction: column;
    }
    
    .requirements {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .signup-container {
        padding: 72px 12px 12px; /* Adjust for smallest nav */
    }
    
    .signup-card {
        padding: 28px 20px;
        border-radius: 24px;
    }
    
    h1 {
        font-size: 1.75rem;
    }

    input[type="email"],
    input[type="password"],
    input[type="tel"],
    input[type="text"],
    select,
    .btn-primary {
        font-size: 1rem;
        padding: 16px 18px;
    }
}

/* ==========================================
   ACCESSIBILITY & EXTRAS
   ========================================== */

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

*:focus-visible {
    outline: 2px solid var(--signup-accent);
    outline-offset: 3px;
    border-radius: 8px;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--signup-surface);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb {
    background: var(--signup-border);
    border-radius: 5px;
    transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--signup-accent);
}

/* Selection Colors */
::selection {
    background: var(--signup-accent-soft);
    color: var(--signup-text-primary);
}

::-moz-selection {
    background: var(--signup-accent-soft);
    color: var(--signup-text-primary);
}

/* Print Styles */
@media print {
    .signup-backdrop,
    .theme-toggle,
    .language-selector {
        display: none !important;
    }

    .signup-card {
        box-shadow: none !important;
        border: 1px solid #ddd !important;
    }
}
