:root {
    /* Nord Star LIGHT Blue Theme Color Palette */
    --primary: #3b82f6;
    --primary-hover: #2563eb;
    --primary-glow: rgba(59, 130, 246, 0.15);
    
    --secondary: #60a5fa;
    --secondary-hover: #3b82f6;
    
    /* LIGHT Theme Neutrals */
    --bg-main: #f1f5f9;
    --bg-card: #ffffff;
    --bg-glass: rgba(255, 255, 255, 0.8);
    --border-light: #e2e8f0;
    --border-focus: #3b82f6;
    
    --text-main: #0f172a;
    --text-muted: #475569;
    --text-dim: #94a3b8;
    
    /* Functional Colors */
    --success: #10b981;
    --error: #ef4444;
    --warning: #f59e0b;
    
    /* Geometry */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 32px;
    
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    
    --shadow-soft: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

/* Modern Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: var(--font-sans);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Navigation */
.header-nav-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 72px;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-light);
    z-index: 1000;
    display: flex;
    align-items: center;
    box-shadow: var(--shadow-soft);
}

.header-nav-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 24px;
}

.site-logo {
    text-decoration: none;
    display: flex;
    align-items: center;
}

.site-logo h1 {
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--text-main) 0%, var(--primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.5px;
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 8px;
}

.main-nav a {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.95rem;
    font-weight: 600;
    padding: 10px 20px;
    border-radius: var(--radius-md);
    transition: all 0.2s ease;
}

.main-nav a:hover {
    color: var(--text-main);
    background: rgba(0, 0, 0, 0.05);
}

.main-nav a.active {
    color: white;
    background: var(--primary);
    box-shadow: 0 4px 12px var(--primary-glow);
}

/* Main Layout */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 112px 24px 60px;
}

.main-content {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

/* Typography */
h1, h2, h3, h4 {
    letter-spacing: -0.02em;
    color: var(--text-main);
}

header h1 {
    font-size: 2.5rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 8px;
}

header h1 span {
    font-size: 1rem;
    color: var(--text-muted);
    font-weight: 400;
    display: block;
    margin-top: 8px;
}

/* Card Styling */
.form-group, .instructions-container, .confirmation-container, .instruction-block, .contact-card, .download-card, .guide-section {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 32px;
    box-shadow: var(--shadow-soft);
    display: flex;
    flex-direction: column;
}

.instructions-title {
    text-align: center;
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 32px;
    width: 100%;
}

.instruction-block h2, .instruction-block h3 {
    margin-bottom: 16px;
}

.instruction-block p {
    margin-bottom: 16px;
    flex-grow: 1;
}

/* Warning Message */
.warning-message {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    border-left: 4px solid var(--warning);
    background: rgba(245, 158, 11, 0.05);
    padding: 20px;
    border-radius: var(--radius-md);
    margin-bottom: 16px;
}

.warning-message p {
    margin: 0;
    color: #92400e;
    font-size: 18px;
}

/* Form Elements */
.form-group {
    margin: 0 auto;
    width: 100%;
}

.form-group label {
    display: block;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--text-main);
}

.input-wrapper {
    position: relative;
    margin-bottom: 24px;
}

input[type="text"], textarea {
    width: 100%;
    background: #ffffff;
    border: 2px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 16px;
    color: var(--text-main);
    font-size: 1rem;
    font-family: 'JetBrains Mono', monospace;
    transition: all 0.2s ease;
}

input[type="text"]:focus, textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-glow);
}

/* Buttons */
button, .btn, .warning-button, .ms-Button, .download-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 32px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    width: auto;
    text-decoration: none;
}

button:hover, .btn:hover, .download-button:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 8px 16px var(--primary-glow);
}

.btn-secondary {
    background: #ffffff;
    border: 1px solid var(--border-light);
    color: var(--text-main);
}

.btn-secondary:hover {
    background: #f8fafc;
}

button:disabled {
    background: var(--text-dim);
    cursor: not-allowed;
}

#copyKeyButton, .copy-all-button {
    background: #ffffff;
    color: var(--text-main);
    margin-top: 16px;
    border: 1px solid var(--border-light);
}

/* Tabs */
.home-instructions-tabs, .instructions-tabs, .downloads-tabs {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 32px;
    background: transparent !important;
    padding: 0 !important;
    box-shadow: none !important;
}

.tab-button {
    background: #ffffff;
    border: 1px solid var(--border-light);
    color: var(--text-muted);
    padding: 12px 32px;
    border-radius: var(--radius-xl);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.tab-button.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    box-shadow: 0 4px 12px var(--primary-glow);
}

/* Instruction Block */
.instruction-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-light);
}

.slider-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.prev-slide, .next-slide {
    padding: 8px 16px;
    font-size: 0.85rem;
    background: #ffffff;
    color: var(--text-main);
    border-radius: var(--radius-sm);
    cursor: pointer;
    border: 1px solid var(--border-light);
}

.slide-indicators {
    display: flex;
    gap: 8px;
}

.indicator {
    width: 64px;
    height: 28px;
    border-radius: var(--radius-sm);
    background: #ffffff;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid var(--border-light);
    transition: all 0.2s ease;
}

.indicator:hover {
    background: #f8fafc;
    color: var(--text-main);
    border-color: var(--primary);
}

.indicator.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    box-shadow: 0 4px 12px var(--primary-glow);
}

.slide {
    display: none;
}

.slide.active {
    display: block;
}

/* Images & Grid */
.instruction-image, .step-img {
    width: fit-content;
    max-width: 100%;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border-light);
    margin: 20px auto;
    background: white;
    display: flex;
    justify-content: center;
}

.instruction-image img, .step-img img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Activation Wizard Styles */
.activation-wizard-container {
    max-width: 100%;
    width: 100%;
    margin: 20px auto;
    background: var(--bg-card);
    padding: 32px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-lg);
    color: var(--text-main);
}

.wizard-steps-indicator {
    display: flex;
    justify-content: space-between;
    margin-bottom: 40px;
    position: relative;
}

.wizard-steps-indicator::before {
    content: '';
    position: absolute;
    top: 17px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--border-light);
    z-index: 0;
}

.wizard-step-badge {
    width: 36px;
    height: 36px;
    background: #ffffff;
    border: 2px solid var(--border-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-weight: 700;
    position: relative;
    z-index: 1;
    transition: 0.3s all ease;
}

.wizard-step-badge.active { 
    background: var(--primary); 
    border-color: var(--primary);
    color: #fff;
    box-shadow: 0 0 15px var(--primary-glow);
}

.wizard-step-badge.completed { 
    background: var(--success); 
    border-color: var(--success);
    color: #fff;
}

.wizard-step-content { 
    display: none; 
    animation: wizardFadeIn 0.4s ease-out; 
}

.wizard-step-content.active { 
    display: block; 
}

@keyframes wizardFadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.wizard-instruction-box {
    background: #f8fafc;
    border-left: 4px solid var(--primary);
    padding: 16px;
    margin: 20px 0;
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    font-size: 18px;
    color: var(--text-main);
}

.wizard-blocks-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 12px;
    margin: 20px 0;
}

.wizard-block-item label {
    display: block;
    text-align: center;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.wizard-block-item input {
    text-align: center;
    background: #ffffff !important;
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    padding: 12px !important;
    color: var(--text-main) !important;
}

.product-type-toggle {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
}

.product-type-btn {
    flex: 1;
    padding: 12px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-light);
    background: #ffffff;
    color: var(--text-muted);
    cursor: pointer;
    transition: 0.2s;
    font-weight: 600;
}

.product-type-btn.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.wizard-nav-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 32px;
}

.wizard-key-display-wrapper {
    display: flex;
    gap: 12px;
    margin: 20px auto;
    max-width: 600px;
    width: 100%;
}

.wizard-key-display-wrapper input {
    flex-grow: 1;
    background: #ffffff;
    font-family: 'JetBrains Mono', monospace;
    min-width: 0;
}

/* Wizard Help/Details Section */
.wizard-help-section details summary::-webkit-details-marker {
    display: none;
}

.wizard-help-section details[open] .toggle-icon {
    transform: rotate(180deg);
}

.wizard-help-section .toggle-icon {
    transition: transform 0.3s ease;
    color: var(--text-muted);
}

.wizard-help-section summary:hover {
    background: rgba(0, 0, 0, 0.02);
}

.confirmation-block {
    background: #f8fafc;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    padding: 16px;
    text-align: center;
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--text-main);
}

/* Grid Layouts */
.instructions-grid, .download-grid, .contact-grid, .product-sections, .downloads-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
}

.downloads-grid {
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
}

@media (min-width: 768px) {
    .download-grid, .contact-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
}

/* Downloads specific */
.downloads-tabs .tab-button img {
    width: 24px;
    height: 24px;
}

.download-section {
    margin-bottom: 60px;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-light);
}

.section-icon {
    width: 32px;
    height: 32px;
    object-fit: contain;
    flex-shrink: 0;
}

.download-card {
    background: #ffffff;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 24px;
    transition: all 0.2s ease;
    max-width: 510px;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
}

.download-card:hover {
    background: #ffffff;
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
}

.card-icon {
    width: 28px;
    height: 28px;
    object-fit: contain;
    flex-shrink: 0;
}

.card-title {
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1.3;
}

.flag-icon {
    width: 20px;
    height: auto;
    border-radius: 2px;
    flex-shrink: 0;
}

.download-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Message Styling */
.message {
    padding: 16px 20px;
    border-radius: var(--radius-md);
    margin-bottom: 24px;
    font-weight: 500;
    display: none;
    text-align: center;
    animation: slideDown 0.3s ease;
}

.message.error {
    background: #fef2f2;
    color: #ef4444;
    border: 1px solid #fee2e2;
}

.message.success {
    background: #ecfdf5;
    color: #10b981;
    border: 1px solid #d1fae5;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .container { padding-top: 100px; padding-left: 16px; padding-right: 16px; }
    header h1 { font-size: 1.8rem; }
    header h1 span { font-size: 0.9rem; }
    
    .activation-wizard-container {
        padding: 20px 16px;
    }

    .wizard-steps-indicator {
        margin-bottom: 30px;
    }

    .wizard-step-badge {
        width: 30px;
        height: 30px;
        font-size: 0.9rem;
    }

    .wizard-steps-indicator::before {
        top: 15px;
    }

    .wizard-instruction-box {
        padding: 12px;
        font-size: 16px;
    }

    /* Mobile Navigation */
    .mobile-menu-toggle {
        display: block;
        background: transparent;
        border: none;
        cursor: pointer;
        padding: 8px;
        z-index: 1001;
    }
    
    .mobile-menu-toggle svg {
        stroke: var(--text-main);
    }

    .main-nav {
        position: fixed;
        top: 72px;
        left: 0;
        width: 100%;
        height: 0;
        background: #ffffff;
        overflow: hidden;
        transition: height 0.3s ease;
        z-index: 1000;
        border-bottom: 1px solid var(--border-light);
    }

    .main-nav.mobile-active {
        height: auto;
        padding: 20px 0;
    }

    .main-nav ul {
        flex-direction: column;
        align-items: center;
        gap: 16px;
    }

    .main-nav a {
        font-size: 1.1rem;
        width: 100%;
        text-align: center;
        padding: 12px;
    }

    .header-nav-container {
        padding: 0 16px;
    }

    .wizard-blocks-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }

    .iid-input-block {
        padding: 8px !important;
        font-size: 1rem;
    }

    .wizard-key-display-wrapper {
        flex-direction: column;
    }

    .wizard-key-display-wrapper button {
        width: 100%;
    }

    .product-type-toggle {
        flex-direction: column;
    }

    .product-type-btn {
        width: 100%;
    }

    .wizard-nav-buttons {
        flex-direction: column;
        gap: 12px;
    }

    .wizard-nav-buttons button {
        width: 100%;
    }

    /* Fix for the absolute positioned button */
    #wizardInstrWindows div[style*="display: flex"] {
        flex-direction: column;
        align-items: stretch !important;
    }

    #wizardInstrWindows button.btn-secondary {
        width: 100% !important;
        position: static !important;
        margin-top: 10px;
    }

    .instruction-image img {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    header h1 { font-size: 1.5rem; }
    .wizard-blocks-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 769px) {
    .mobile-menu-toggle {
        display: none;
    }
}
