/* ==============================================
   FundIQ Camp Registration Styles
   Extends the base style.css design system
   ============================================== */

/* Camp Hero Section */
.camp-hero {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 2.5rem 0;
    text-align: center;
}
.camp-hero h1 {
    font-size: 1.75rem;
    font-weight: 800;
    margin: 0 0 0.5rem 0;
}
.camp-hero p {
    opacity: 0.9;
    margin: 0;
    font-size: 1rem;
}
@media (min-width: 768px) {
    .camp-hero h1 { font-size: 2.25rem; }
    .camp-hero p { font-size: 1.125rem; }
}

/* Session Cards */
.session-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: 1fr;
}
@media (min-width: 640px) {
    .session-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
    .session-grid { grid-template-columns: repeat(3, 1fr); }
}

.session-card {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 1.5rem;
    transition: all 0.2s ease;
    border: 2px solid transparent;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}
.session-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
}
.session-card .session-sport {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--primary);
    margin-bottom: 0.5rem;
}
.session-card .session-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 0.75rem;
}
.session-card .session-detail {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--gray-600);
    margin-bottom: 0.375rem;
}
.session-card .session-detail svg {
    width: 1rem;
    height: 1rem;
    flex-shrink: 0;
    color: var(--gray-400);
}
.session-card .session-price {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--gray-100);
    display: flex;
    align-items: baseline;
    justify-content: space-between;
}
.session-card .session-price .price-amount {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary);
}
.session-card .session-price .price-label {
    font-size: 0.75rem;
    color: var(--gray-500);
}

/* Early Bird Badge */
.early-bird-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    background: #fef3c7;
    color: #92400e;
    padding: 0.25rem 0.625rem;
    border-radius: 9999px;
    font-size: 0.6875rem;
    font-weight: 600;
}
.price-strikethrough {
    text-decoration: line-through;
    color: var(--gray-400);
    font-size: 0.875rem;
    font-weight: 400;
}

/* Spots Remaining */
.spots-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.625rem;
    border-radius: 9999px;
    font-size: 0.6875rem;
    font-weight: 600;
}
.spots-badge.available {
    background: #d1fae5;
    color: #065f46;
}
.spots-badge.limited {
    background: #fef3c7;
    color: #92400e;
}
.spots-badge.full {
    background: #fee2e2;
    color: #991b1b;
}

/* T-shirt Size Grid */
.tshirt-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
}
@media (min-width: 640px) {
    .tshirt-grid { grid-template-columns: repeat(8, 1fr); }
}
.tshirt-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 0.25rem;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.15s ease;
    background: white;
    text-align: center;
}
.tshirt-option:hover {
    border-color: var(--primary-light);
    background: rgba(30, 64, 175, 0.03);
}
.tshirt-option.selected {
    border-color: var(--primary);
    background: rgba(30, 64, 175, 0.08);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}
.tshirt-option .size-code {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--gray-900);
}
.tshirt-option .size-label {
    font-size: 0.625rem;
    color: var(--gray-500);
    margin-top: 0.125rem;
    line-height: 1.2;
}

/* Camp Progress Steps (4 steps) */
.camp-progress {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 1.5rem 1rem;
}
.camp-progress .step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.375rem;
    position: relative;
    z-index: 1;
}
.camp-progress .step-circle {
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    border: 2px solid var(--gray-300);
    background: white;
    color: var(--gray-400);
    transition: all 0.3s ease;
}
.camp-progress .step.active .step-circle {
    border-color: var(--primary);
    background: var(--primary);
    color: white;
}
.camp-progress .step.completed .step-circle {
    border-color: #10b981;
    background: #10b981;
    color: white;
}
.camp-progress .step-label {
    font-size: 0.625rem;
    font-weight: 500;
    color: var(--gray-400);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    white-space: nowrap;
}
.camp-progress .step.active .step-label,
.camp-progress .step.completed .step-label {
    color: var(--gray-700);
}
.camp-progress .step-line {
    flex: 1;
    height: 2px;
    background: var(--gray-200);
    min-width: 2rem;
    max-width: 5rem;
    margin: 0 0.25rem;
    margin-bottom: 1.25rem;
    transition: background 0.3s ease;
}
.camp-progress .step-line.completed {
    background: #10b981;
}
@media (max-width: 400px) {
    .camp-progress .step-line { min-width: 1rem; }
    .camp-progress .step-label { font-size: 0.5625rem; }
}

/* Step Panels */
.step-panel {
    display: none;
}
.step-panel.active {
    display: block;
    animation: stepFadeIn 0.3s ease;
}
@keyframes stepFadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Medical Yes/No Toggle */
.toggle-group {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}
.toggle-option {
    flex: 1;
    max-width: 100px;
}
.toggle-option input[type="radio"] {
    display: none;
}
.toggle-option label {
    display: block;
    text-align: center;
    padding: 0.5rem 1rem;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius);
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--gray-600);
    transition: all 0.15s ease;
}
.toggle-option input[type="radio"]:checked + label {
    border-color: var(--primary);
    background: rgba(30, 64, 175, 0.08);
    color: var(--primary);
}
.conditional-field {
    display: none;
    margin-top: 0.5rem;
}
.conditional-field.visible {
    display: block;
    animation: stepFadeIn 0.2s ease;
}

/* Waiver Text Box */
.waiver-text {
    max-height: 180px;
    overflow-y: auto;
    padding: 1rem;
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    font-size: 0.8125rem;
    line-height: 1.6;
    color: var(--gray-700);
    margin-bottom: 1rem;
}
.waiver-text::-webkit-scrollbar {
    width: 6px;
}
.waiver-text::-webkit-scrollbar-thumb {
    background: var(--gray-300);
    border-radius: 3px;
}

/* Signature Input */
.signature-input {
    font-family: 'Brush Script MT', 'Segoe Script', cursive;
    font-size: 1.5rem;
    padding: 0.75rem 1rem;
    border: 2px dashed var(--gray-300);
    border-radius: var(--radius);
    width: 100%;
    text-align: center;
    color: var(--gray-800);
    transition: border-color 0.2s ease;
}
.signature-input:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}
.signature-input::placeholder {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 0.875rem;
    color: var(--gray-400);
}

/* Add-on Items */
.addon-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.addon-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.15s ease;
}
.addon-item:hover {
    border-color: var(--primary-light);
    background: rgba(30, 64, 175, 0.02);
}
.addon-item.selected {
    border-color: var(--primary);
    background: rgba(30, 64, 175, 0.05);
}
.addon-item input[type="checkbox"] {
    display: none;
}
.addon-check {
    width: 1.25rem;
    height: 1.25rem;
    border: 2px solid var(--gray-300);
    border-radius: 4px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}
.addon-item.selected .addon-check {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}
.addon-info {
    flex: 1;
}
.addon-name {
    font-weight: 600;
    font-size: 0.9375rem;
    color: var(--gray-900);
}
.addon-desc {
    font-size: 0.75rem;
    color: var(--gray-500);
}
.addon-price {
    font-weight: 700;
    font-size: 0.9375rem;
    color: var(--primary);
    white-space: nowrap;
}

/* Order Summary (Camp) */
.camp-summary {
    background: var(--gray-50);
    border-radius: var(--radius);
    padding: 1rem;
}
.camp-summary .summary-line {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    font-size: 0.9375rem;
    color: var(--gray-700);
}
.camp-summary .summary-line + .summary-line {
    border-top: 1px solid var(--gray-200);
}
.camp-summary .summary-total {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--gray-900);
    border-top: 2px solid var(--gray-300);
    margin-top: 0.25rem;
    padding-top: 0.75rem;
}
.camp-summary .discount-line {
    color: #059669;
}

/* Navigation Buttons */
.step-nav {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}
.step-nav .btn {
    flex: 1;
}
.step-nav .btn-back {
    flex: 0 0 auto;
    min-width: 100px;
}

/* Confirmation Page */
.confirmation-icon {
    width: 4rem;
    height: 4rem;
    border-radius: 50%;
    background: #d1fae5;
    color: #059669;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}
.confirmation-code {
    font-size: 1.75rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    color: var(--primary);
    text-align: center;
    padding: 1rem;
    background: rgba(30, 64, 175, 0.05);
    border-radius: var(--radius);
    margin: 1rem 0;
}

/* Card toggle (same as checkout.php) */
.card-toggle-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.75rem 1rem;
    background: transparent;
    border: 1px dashed var(--gray-300);
    border-radius: 8px;
    color: var(--gray-600);
    font-size: 0.9375rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}
.card-toggle-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(30, 64, 175, 0.05);
}
.card-toggle-btn .chevron-icon {
    transition: transform 0.2s ease;
}
.card-toggle-btn.expanded .chevron-icon {
    transform: rotate(180deg);
}
#card-fields-container {
    transition: all 0.3s ease;
    overflow: hidden;
}
#card-fields-container.collapsed {
    max-height: 0;
    opacity: 0;
    margin: 0;
    padding: 0;
}
#card-fields-container.expanded {
    max-height: 500px;
    opacity: 1;
    margin-top: 1rem;
}

/* Print styles */
@media print {
    .header, .footer, .btn, .step-nav, .no-print { display: none !important; }
    .camp-progress { display: none !important; }
    body { font-size: 12pt; }
    .card { box-shadow: none; border: 1px solid #ddd; }
    .confirmation-code { background: white; border: 2px solid #2563eb; }
}
