﻿/* ===========================
   FORM STYLES
   =========================== */

.create-page {
    min-height: 100svh;
    padding: 100px 0 60px;
}

.form-header {
    text-align: center;
    margin-bottom: 40px;
}

.form-header h1 {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 12px;
}

.form-header p {
    color: var(--text-muted);
    font-size: 1.05rem;
}

/* Progress Bar */
.progress-bar {
    position: relative;
    margin-bottom: 48px;
    padding: 0 20px;
}

.progress-fill {
    position: absolute;
    top: 18px;
    left: 60px;
    right: 60px;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    z-index: 0;
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 0%;
    background: var(--gradient-gold);
    border-radius: 3px;
    transition: width 0.5s ease;
}

.progress-steps {
    display: flex;
    justify-content: space-between;
    position: relative;
    z-index: 1;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.step-dot {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 2px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 600;
    transition: var(--transition);
}

.progress-step.active .step-dot {
    background: var(--primary);
    border-color: var(--primary);
    color: #1a1a2e;
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.4);
}

.progress-step.completed .step-dot {
    background: #4caf50;
    border-color: #4caf50;
    color: white;
}

.step-text {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
}

.progress-step.active .step-text {
    color: var(--primary);
}

/* Form Steps */
.form-step {
    display: none;
    animation: fadeInUp 0.5s ease;
}

.form-step.active {
    display: block;
}

.step-title {
    font-family: var(--font-display);
    font-size: 1.6rem;
    margin-bottom: 24px;
    text-align: center;
}

.step-desc {
    color: var(--text-muted);
    text-align: center;
    margin-bottom: 30px;
}

/* Form Groups */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: var(--text-light);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 14px 18px;
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-sm);
    color: var(--text-white);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition);
    outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.15);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
}

/* File Upload */
.file-upload {
    position: relative;
    border: 2px dashed rgba(255, 255, 255, 0.15);
    border-radius: var(--radius-md);
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    overflow: hidden;
}

.file-upload:hover {
    border-color: var(--primary);
    background: rgba(212, 175, 55, 0.05);
}

.file-upload input[type="file"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.file-upload-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.upload-icon {
    font-size: 2.5rem;
}

.upload-text {
    color: var(--text-light);
    font-weight: 500;
}

.upload-hint {
    color: var(--text-muted);
    font-size: 0.8rem;
}

.photo-preview {
    display: none;
    max-height: 200px;
    border-radius: var(--radius-sm);
    margin-top: 16px;
}

.photo-preview.visible {
    display: block;
}

/* Template Selection in Form */
.template-select-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
}

.template-option {
    background: var(--bg-card);
    border: 2px solid rgba(255, 255, 255, 0.06);
    border-radius: var(--radius-lg);
    padding: 24px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
}

.template-option:hover {
    border-color: rgba(212, 175, 55, 0.3);
    transform: translateY(-4px);
}

.template-option.selected {
    border-color: var(--primary);
    background: rgba(212, 175, 55, 0.08);
    box-shadow: 0 0 30px rgba(212, 175, 55, 0.15);
}

.template-option-icon {
    font-size: 3rem;
    margin-bottom: 12px;
}

.template-option h3 {
    font-family: var(--font-display);
    font-size: 1.2rem;
    margin-bottom: 8px;
    color: var(--text-white);
}

.template-option p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* Subdomain Input */
.subdomain-input-wrapper {
    max-width: 500px;
    margin: 0 auto 20px;
}

.subdomain-input-group {
    display: flex;
    align-items: stretch;
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition);
}

.subdomain-input-group:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.15);
}

.subdomain-input-group input {
    flex: 1;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding: 14px 18px;
    font-size: 1.1rem;
    font-weight: 600;
}

.subdomain-suffix {
    background: rgba(212, 175, 55, 0.15);
    color: var(--primary);
    padding: 14px 16px;
    font-weight: 600;
    font-size: 0.95rem;
    white-space: nowrap;
    display: flex;
    align-items: center;
}

.subdomain-status {
    text-align: center;
    margin-top: 10px;
    font-size: 0.9rem;
    min-height: 20px;
}

.subdomain-status.available {
    color: #4caf50;
}

.subdomain-status.taken {
    color: #f44336;
}

.subdomain-status.checking {
    color: var(--text-muted);
}

.subdomain-hint {
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Review Card */
.review-card {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    padding: 32px;
    margin-bottom: 30px;
}

.review-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.review-item:last-child {
    border-bottom: none;
}

.review-label {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.review-value {
    font-weight: 600;
    color: var(--text-white);
    text-align: right;
}

/* Payment Info */
.payment-info {
    background: var(--bg-card);
    border: 2px solid rgba(212, 175, 55, 0.2);
    border-radius: var(--radius-lg);
    padding: 32px;
    text-align: center;
}

.payment-icon {
    font-size: 3rem;
    margin-bottom: 12px;
}

.payment-info h3 {
    font-family: var(--font-display);
    font-size: 1.3rem;
    margin-bottom: 12px;
}

.payment-price {
    font-family: var(--font-display);
    font-size: 2.5rem;
    font-weight: 700;
    background: var(--gradient-gold);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 12px;
}

.payment-desc {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 16px;
}

/* Card Number Box */
.card-number-box {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: var(--radius-md);
    padding: 20px;
    margin: 20px 0;
}

.card-label {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-bottom: 10px;
}

.card-number-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.card-number {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 3px;
    color: var(--primary);
    font-family: 'Courier New', monospace;
}

.btn-copy {
    background: rgba(212, 175, 55, 0.15);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 8px;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s;
    color: var(--primary);
}

.btn-copy:hover {
    background: rgba(212, 175, 55, 0.3);
    transform: scale(1.1);
}

.card-holder {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 8px;
}

/* Payment Steps */
.payment-steps {
    margin: 20px 0;
    text-align: left;
}

.payment-step {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.payment-step:last-child {
    border-bottom: none;
}

.payment-step-num {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(212, 175, 55, 0.15);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
    flex-shrink: 0;
}

.payment-step span:last-child {
    font-size: 0.9rem;
    color: var(--text-light);
}

/* Telegram Button */
.btn-telegram {
    background: linear-gradient(135deg, #0088cc, #00a8e8) !important;
    color: white !important;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    -webkit-text-fill-color: white !important;
}

.btn-telegram:hover {
    box-shadow: 0 8px 25px rgba(0, 136, 204, 0.4);
    transform: translateY(-3px);
}

/* Payment Reminder (Success Page) */
.payment-reminder {
    background: var(--bg-card);
    border: 2px solid rgba(212, 175, 55, 0.2);
    border-radius: var(--radius-lg);
    padding: 32px;
    margin: 24px auto;
    max-width: 500px;
    text-align: center;
}

.payment-reminder h3 {
    font-family: var(--font-display);
    font-size: 1.2rem;
    margin-bottom: 12px;
}

.payment-reminder p {
    color: var(--text-light);
    font-size: 0.9rem;
}

.payment-note {
    color: var(--primary);
    font-weight: 500;
    margin-top: 16px;
    font-size: 0.85rem;
}

.success-card {
    margin: 12px 0;
}

/* Form Navigation */
.form-nav {
    display: flex;
    justify-content: space-between;
    margin-top: 32px;
    gap: 16px;
}

/* Success Page */
.success-page {
    text-align: center;
    padding: 60px 0;
    animation: fadeInUp 0.6s ease;
}

.success-icon {
    font-size: 5rem;
    margin-bottom: 24px;
}

.success-page h2 {
    font-family: var(--font-display);
    font-size: 2rem;
    margin-bottom: 12px;
    background: var(--gradient-gold);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.success-page>p {
    color: var(--text-muted);
    margin-bottom: 24px;
}

.success-details {
    background: var(--bg-card);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin: 24px auto;
    max-width: 500px;
    text-align: left;
}

.success-note {
    color: var(--primary);
    font-weight: 500;
    margin: 24px 0;
}

/* Responsive */
@media (max-width: 768px) {
    .create-page {
        padding: 80px 15px 40px;
    }

    .step-dot {
        width: 30px;
        height: 30px;
        font-size: 0.75rem;
    }

    .progress-fill {
        left: 40px;
        right: 40px;
        top: 15px;
    }

    .progress-bar {
        padding: 0 10px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .template-select-grid {
        grid-template-columns: 1fr;
    }

    .step-text {
        display: none;
    }

    .progress-step.active .step-text {
        display: block;
    }

    .subdomain-input-group {
        flex-direction: column;
    }

    .subdomain-suffix {
        justify-content: center;
    }

    .form-nav {
        flex-direction: column-reverse;
    }

    .form-nav .btn {
        width: 100%;
        justify-content: center;
    }
}