/* ============================================
   Drive Icon Generator - Stylesheet
   With Dark Mode Support
   ============================================ */

:root {
    --transition-speed: 0.25s;
    
    /* Primary Colors */
    --primary: #3B82F6;
    --primary-light: #DBEAFE;
    --primary-dark: #2563EB;
    --accent: #60A5FA;
    --success: #10B981;
    --success-light: #D1FAE5;
    --warning: #F59E0B;
    --danger: #EF4444;
    --purple: #8B5CF6;
    --purple-light: #EDE9FE;
    --teal: #14B8A6;
    --teal-light: #CCFBF1;
    --orange: #F97316;
    --pink: #EC4899;
    --indigo: #6366F1;
    --cyan: #06B6D4;
    
    /* Background Colors */
    --bg: #f8fafc;
    --bg-elevated: #ffffff;
    --bg-secondary: #f1f5f9;
    
    /* Text Colors */
    --text: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    
    /* Border Colors */
    --border: #e2e8f0;
    --border-light: #f1f5f9;
    
    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.1);
    
    /* Radius */
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
    
    /* Checkerboard */
    --checker-light: #f0f0f0;
    --checker-dark: #d0d0d0;
}

/* Dark Mode */
[data-theme="dark"] {
    --primary: #60A5FA;
    --primary-light: rgba(96, 165, 250, 0.15);
    --primary-dark: #3B82F6;
    --accent: #93C5FD;
    --success: #4ade80;
    --success-light: rgba(74, 222, 128, 0.15);
    --warning: #fbbf24;
    --danger: #f87171;
    --purple: #a78bfa;
    --purple-light: rgba(167, 139, 250, 0.15);
    --teal: #2dd4bf;
    --teal-light: rgba(45, 212, 191, 0.15);
    
    --bg: #0f172a;
    --bg-elevated: #1e293b;
    --bg-secondary: #334155;
    
    --text: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    
    --border: #334155;
    --border-light: #475569;
    
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.3);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.4);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.4);
    --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.5);
    
    --checker-light: #374151;
    --checker-dark: #4b5563;
}

/* Base */
* { box-sizing: border-box; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    margin: 0;
    padding: 0;
    transition: background-color var(--transition-speed), color var(--transition-speed);
}

/* Container */
.tool-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem;
}

/* Header */
.tool-header {
    text-align: center;
    margin-bottom: 2rem;
}

.tool-title-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.tool-icon-inline {
    width: 48px;
    height: 48px;
    color: var(--primary);
}

.tool-title {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 700;
    margin: 0;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tool-description {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 750px;
    margin: 0 auto;
    line-height: 1.7;
}

/* Main Tool Area */
.tool-main {
    background: var(--bg-elevated);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    overflow: hidden;
    border: 1px solid var(--border);
    transition: background-color var(--transition-speed), border-color var(--transition-speed);
}

.tool-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 700px;
}

/* Panels */
.options-panel,
.preview-panel {
    padding: 1.75rem;
}

.options-panel {
    border-right: 1px solid var(--border);
    overflow-y: auto;
    max-height: 850px;
    transition: border-color var(--transition-speed);
}

.preview-panel {
    background: var(--bg-secondary);
    display: flex;
    flex-direction: column;
    transition: background-color var(--transition-speed);
}

.panel-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
    color: var(--text);
}

.panel-header h2 {
    font-size: 1.15rem;
    font-weight: 600;
    margin: 0;
}

.panel-header svg {
    color: var(--primary);
}

/* Option Groups */
.option-group {
    margin-bottom: 1.5rem;
}

.option-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 0.65rem;
}

.option-label svg {
    color: var(--text-muted);
}

/* Drive Type Grid */
.drive-type-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
}

.drive-type-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    padding: 0.75rem 0.5rem;
    border: 2px solid var(--border);
    background: var(--bg);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s ease;
    color: var(--text-muted);
}

.drive-type-btn span {
    font-size: 0.7rem;
    font-weight: 500;
    text-align: center;
    line-height: 1.2;
}

.drive-type-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.drive-type-btn.active {
    border-color: var(--primary);
    background: var(--primary-light);
    color: var(--primary);
}

/* Label Type Tabs */
.label-type-tabs {
    display: flex;
    background: var(--bg);
    border-radius: var(--radius-full);
    padding: 3px;
    border: 1px solid var(--border);
    margin-bottom: 0.75rem;
}

.label-tab {
    flex: 1;
    padding: 0.5rem 0.75rem;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    border-radius: var(--radius-full);
    transition: all 0.2s ease;
}

.label-tab:hover {
    color: var(--text);
}

.label-tab.active {
    background: var(--primary);
    color: white;
}

/* Label Options */
.label-options {
    animation: fadeIn 0.2s ease;
}

/* Capacity Grid */
.capacity-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.4rem;
}

.capacity-btn {
    padding: 0.5rem 0.4rem;
    border: 1px solid var(--border);
    background: var(--bg);
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.capacity-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.capacity-btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* Letter Grid */
.letter-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.letter-btn {
    padding: 0.5rem 0.85rem;
    border: 1px solid var(--border);
    background: var(--bg);
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 700;
    font-family: monospace;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.letter-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.letter-btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* Custom Label Input */
.custom-label-input {
    margin-bottom: 0.65rem;
}

.custom-label-input input {
    width: 100%;
    padding: 0.65rem 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--bg);
    color: var(--text);
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.custom-label-input input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.custom-label-input input::placeholder {
    color: var(--text-muted);
}

/* Quick Labels */
.quick-labels {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.quick-label {
    padding: 0.4rem 0.75rem;
    border: 1px solid var(--border);
    background: var(--bg);
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.quick-label:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-light);
}

/* Color Grid */
.color-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.65rem;
}

.color-btn {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    border: 3px solid transparent;
    background: var(--btn-color);
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}

.color-btn:hover {
    transform: scale(1.1);
}

.color-btn.active {
    border-color: var(--text);
    box-shadow: 0 0 0 2px var(--bg-elevated), 0 0 0 4px var(--btn-color);
}

.color-btn::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    box-shadow: inset 0 2px 4px rgba(255,255,255,0.3), inset 0 -2px 4px rgba(0,0,0,0.2);
}

/* Custom Color */
.custom-color {
    display: flex;
    align-items: center;
    gap: 0.65rem;
}

.custom-color label {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.custom-color input[type="color"] {
    width: 36px;
    height: 28px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    padding: 2px;
    background: var(--bg);
}

/* Text Options */
.text-options {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.option-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.option-row > label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
}

.option-row input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary);
    cursor: pointer;
}

.text-color-options {
    display: flex;
    gap: 0.4rem;
}

.text-color-btn {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    border: 2px solid var(--border);
    background: var(--bg);
    cursor: pointer;
    padding: 3px;
    transition: all 0.2s ease;
}

.text-color-btn span {
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 2px;
}

.text-color-btn:hover {
    border-color: var(--primary);
}

.text-color-btn.active {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px var(--primary-light);
}

/* Text Position Options */
.text-position-options {
    display: flex;
    gap: 0.35rem;
}

.text-pos-btn {
    width: 32px;
    height: 28px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--bg);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    transition: all 0.2s ease;
}

.text-pos-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.text-pos-btn.active {
    border-color: var(--primary);
    background: var(--primary-light);
    color: var(--primary);
}

/* Text Offset Control */
.text-offset-control {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 0.2rem;
}

.offset-btn {
    width: 26px;
    height: 26px;
    border: none;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}

.offset-btn:hover {
    background: var(--primary-light);
    color: var(--primary);
}

.offset-btn:active {
    transform: scale(0.95);
}

.offset-value {
    min-width: 32px;
    text-align: center;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text);
    font-family: monospace;
}

.offset-reset {
    width: 26px;
    height: 26px;
    border: none;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
    margin-left: 0.25rem;
}

.offset-reset:hover {
    background: var(--danger);
    color: white;
}

/* Size Checkboxes */
.size-checkboxes {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.size-checkbox {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.65rem;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.size-checkbox:hover {
    border-color: var(--primary);
}

.size-checkbox:has(input:checked) {
    background: var(--primary-light);
    border-color: var(--primary);
    color: var(--primary);
}

.size-checkbox input {
    width: 14px;
    height: 14px;
    accent-color: var(--primary);
    cursor: pointer;
}

/* Preview Area */
.preview-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    gap: 0.75rem;
}

.preview-main {
    width: 180px;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: 
        linear-gradient(45deg, var(--checker-light) 25%, transparent 25%),
        linear-gradient(-45deg, var(--checker-light) 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, var(--checker-light) 75%),
        linear-gradient(-45deg, transparent 75%, var(--checker-light) 75%);
    background-size: 16px 16px;
    background-position: 0 0, 0 8px, 8px -8px, -8px 0px;
    background-color: var(--checker-dark);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: 0.75rem;
}

.preview-main canvas {
    max-width: 100%;
    max-height: 100%;
    image-rendering: pixelated;
}

.preview-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.preview-type {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.preview-label {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    padding: 0.35rem 1rem;
    background: var(--bg-elevated);
    border-radius: var(--radius-full);
    box-shadow: var(--shadow-sm);
}

/* Size Previews */
.size-previews {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    padding: 0.75rem;
    background: var(--bg-elevated);
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
    flex-wrap: wrap;
    transition: background-color var(--transition-speed);
}

.size-preview {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
}

.size-preview canvas {
    background: 
        linear-gradient(45deg, var(--checker-light) 25%, transparent 25%),
        linear-gradient(-45deg, var(--checker-light) 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, var(--checker-light) 75%),
        linear-gradient(-45deg, transparent 75%, var(--checker-light) 75%);
    background-size: 6px 6px;
    background-position: 0 0, 0 3px, 3px -3px, -3px 0px;
    background-color: var(--checker-dark);
    border-radius: var(--radius-sm);
    image-rendering: pixelated;
}

.size-preview span {
    font-size: 0.7rem;
    color: var(--text-muted);
}

/* Download Section */
.download-section {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    font-size: 0.9rem;
    font-weight: 600;
    border: none;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    flex: 1;
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--bg-elevated);
    color: var(--text);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--bg);
    border-color: var(--text-muted);
}

/* Usage Tips */
.usage-tips {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.usage-tip {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0.85rem;
    background: var(--bg-elevated);
    border-radius: var(--radius-md);
    font-size: 0.8rem;
    color: var(--text-secondary);
    transition: background-color var(--transition-speed);
}

.usage-tip svg {
    color: var(--primary);
    flex-shrink: 0;
}

.usage-tip strong {
    color: var(--text);
}

.usage-tip code {
    background: var(--bg-secondary);
    padding: 0.15rem 0.4rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-family: monospace;
}

/* Related Tools */
.related-tools {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 2rem;
    padding: 1.25rem 1.5rem;
    background: var(--bg-elevated);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    flex-wrap: wrap;
    transition: background-color var(--transition-speed), border-color var(--transition-speed);
}

.related-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
}

.related-label svg {
    color: var(--primary);
}

.related-links {
    display: flex;
    gap: 0.65rem;
    flex-wrap: wrap;
    flex: 1;
}

.tool-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 0.85rem;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
}

.tool-link:hover {
    background: var(--primary-light);
    border-color: var(--primary);
    color: var(--primary);
}

/* Info Sections */
.info-sections {
    margin-top: 2rem;
}

.info-card {
    background: var(--bg-elevated);
    border-radius: var(--radius-lg);
    padding: 1.75rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--border);
    transition: background-color var(--transition-speed), border-color var(--transition-speed);
}

.info-card h2 {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.25rem;
    margin: 0 0 1.25rem;
    color: var(--text);
}

.info-card h2 svg {
    color: var(--primary);
}

/* Steps List */
.steps-list {
    list-style: none;
    padding: 0;
    margin: 0;
    counter-reset: step;
}

.steps-list li {
    position: relative;
    padding-left: 3rem;
    padding-bottom: 1rem;
    counter-increment: step;
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.9rem;
}

.steps-list li:last-child {
    padding-bottom: 0;
}

.steps-list li:not(:last-child)::after {
    content: '';
    position: absolute;
    left: calc(0.875rem - 1px);
    top: 1.75rem;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, var(--primary-light), var(--success-light));
}

.steps-list li::before {
    content: counter(step);
    position: absolute;
    left: 0;
    top: 0;
    width: 1.75rem;
    height: 1.75rem;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.8rem;
    z-index: 1;
}

.steps-list li strong {
    color: var(--text);
}

/* Steps Tip */
.steps-tip {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    margin-top: 1.25rem;
    padding: 0.85rem 1rem;
    background: var(--primary-light);
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    color: var(--text);
    line-height: 1.5;
}

.steps-tip svg {
    color: var(--primary);
    flex-shrink: 0;
    margin-top: 2px;
}

.steps-tip code {
    background: var(--bg-secondary);
    padding: 0.15rem 0.4rem;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-family: monospace;
}

/* Autorun.inf Card */
.autorun-card {
    background: linear-gradient(135deg, var(--bg-elevated), var(--bg));
}

.autorun-intro {
    color: var(--text-secondary);
    margin: 0 0 1.25rem;
    line-height: 1.6;
}

.autorun-intro code {
    background: var(--bg-secondary);
    padding: 0.15rem 0.5rem;
    border-radius: var(--radius-sm);
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 0.9em;
    color: var(--primary);
}

/* Code Block */
.code-block {
    background: var(--code-bg, #1e1e1e);
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: 1.5rem;
}

[data-theme="dark"] .code-block {
    background: #0d1117;
}

.code-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.code-filename {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #8b949e;
    font-size: 0.85rem;
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
}

.code-filename svg {
    opacity: 0.7;
}

.copy-btn {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.85rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: var(--radius-sm);
    color: #8b949e;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.copy-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    border-color: rgba(255, 255, 255, 0.25);
}

.copy-btn.copied {
    background: rgba(16, 185, 129, 0.2);
    border-color: rgba(16, 185, 129, 0.4);
    color: #10B981;
}

.code-content {
    margin: 0;
    padding: 1.25rem;
    color: #c9d1d9;
    font-family: 'JetBrains Mono', 'Fira Code', 'Monaco', 'Consolas', monospace;
    font-size: 0.9rem;
    line-height: 1.7;
    overflow-x: auto;
    white-space: pre;
}

/* Autorun Instructions */
.autorun-instructions {
    background: var(--bg);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    margin-bottom: 1.25rem;
    transition: background-color var(--transition-speed);
}

.autorun-instructions h3 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0 0 1rem;
    font-size: 1rem;
    color: var(--text);
}

.autorun-instructions h3 svg {
    color: var(--primary);
}

.autorun-instructions ol {
    margin: 0;
    padding-left: 1.25rem;
    color: var(--text-secondary);
}

.autorun-instructions ol li {
    margin-bottom: 0.5rem;
    padding-left: 0.5rem;
    line-height: 1.5;
}

.autorun-instructions ol li:last-child {
    margin-bottom: 0;
}

.autorun-instructions ol li strong {
    color: var(--text);
}

/* Autorun Notes */
.autorun-notes {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.note-item {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    padding: 0.75rem 1rem;
    background: var(--bg);
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
    transition: background-color var(--transition-speed);
}

.note-item svg {
    color: var(--text-muted);
    flex-shrink: 0;
    margin-top: 2px;
}

.note-item strong {
    color: var(--text);
}

.note-item code {
    background: var(--bg-secondary);
    padding: 0.1rem 0.35rem;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-family: monospace;
    color: var(--primary);
}

/* Drive Types Grid */
.drive-types-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.drive-type-info {
    padding: 1.25rem;
    background: var(--bg);
    border-radius: var(--radius-md);
    text-align: center;
    transition: background-color var(--transition-speed);
}

.drive-type-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 0.75rem;
}

.drive-type-icon.blue { background: rgba(59, 130, 246, 0.15); color: #3B82F6; }
.drive-type-icon.green { background: rgba(16, 185, 129, 0.15); color: #10B981; }
.drive-type-icon.purple { background: rgba(139, 92, 246, 0.15); color: #8B5CF6; }
.drive-type-icon.orange { background: rgba(249, 115, 22, 0.15); color: #F97316; }
.drive-type-icon.teal { background: rgba(20, 184, 166, 0.15); color: #14B8A6; }
.drive-type-icon.pink { background: rgba(236, 72, 153, 0.15); color: #EC4899; }
.drive-type-icon.indigo { background: rgba(99, 102, 241, 0.15); color: #6366F1; }
.drive-type-icon.gray { background: rgba(107, 114, 128, 0.15); color: #6B7280; }
.drive-type-icon.cyan { background: rgba(6, 182, 212, 0.15); color: #06B6D4; }

.drive-type-info h3 {
    margin: 0 0 0.4rem;
    font-size: 0.95rem;
    color: var(--text);
}

.drive-type-info p {
    margin: 0;
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* FAQ */
.faq-list {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.faq-item {
    background: var(--bg);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: background-color var(--transition-speed);
}

.faq-question {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text);
    text-align: left;
    transition: background 0.2s ease;
}

.faq-question:hover {
    background: var(--bg-secondary);
}

.faq-question svg {
    color: var(--text-muted);
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.faq-item.open .faq-question svg {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.faq-item.open .faq-answer {
    max-height: 500px;
}

.faq-answer p {
    padding: 0 1rem 1rem;
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.9rem;
}

.faq-answer a {
    color: var(--primary);
    text-decoration: none;
}

.faq-answer a:hover {
    text-decoration: underline;
}

.faq-answer code {
    background: var(--bg-secondary);
    padding: 0.15rem 0.4rem;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-family: monospace;
}

/* Tools Grid */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 0.85rem;
}

.tool-card {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 1rem;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    text-decoration: none;
    transition: all 0.2s ease;
}

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

.tool-card-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.tool-card-icon.blue { background: rgba(59, 130, 246, 0.15); color: #3B82F6; }
.tool-card-icon.green { background: rgba(16, 185, 129, 0.15); color: #10B981; }
.tool-card-icon.purple { background: rgba(139, 92, 246, 0.15); color: #8B5CF6; }
.tool-card-icon.orange { background: rgba(249, 115, 22, 0.15); color: #F97316; }
.tool-card-icon.teal { background: rgba(20, 184, 166, 0.15); color: #14B8A6; }
.tool-card-icon.pink { background: rgba(236, 72, 153, 0.15); color: #EC4899; }

.tool-card-content h3 {
    margin: 0 0 0.2rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text);
}

.tool-card-content p {
    margin: 0;
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Toast */
.toast-notification {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.85rem 1.25rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    z-index: 10001;
    opacity: 0;
    transition: all 0.3s ease;
}

.toast-notification.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.toast-notification.success svg { color: var(--success); }
.toast-notification.error svg { color: var(--danger); }

/* Responsive */
@media (max-width: 1000px) {
    .tool-layout {
        grid-template-columns: 1fr;
    }
    
    .options-panel {
        border-right: none;
        border-bottom: 1px solid var(--border);
        max-height: none;
    }
    
    .drive-type-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .tool-container {
        padding: 1rem;
    }
    
    .options-panel,
    .preview-panel {
        padding: 1.25rem;
    }
    
    .drive-type-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .capacity-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .download-section {
        flex-direction: column;
    }
    
    .related-tools {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .related-links {
        width: 100%;
    }
    
    .tool-link {
        flex: 1;
        min-width: calc(50% - 0.35rem);
        justify-content: center;
    }
    
    .drive-types-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .tools-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .tool-title-row {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .drive-type-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .drive-type-btn {
        padding: 0.5rem 0.25rem;
    }
    
    .drive-type-btn svg {
        width: 20px !important;
        height: 20px !important;
    }
    
    .drive-type-btn span {
        font-size: 0.6rem;
    }
    
    .label-tab {
        padding: 0.4rem 0.5rem;
        font-size: 0.7rem;
    }
    
    .preview-main {
        width: 150px;
        height: 150px;
    }
    
    .drive-types-grid {
        grid-template-columns: 1fr;
    }
    
    .toast-notification {
        left: 1rem;
        right: 1rem;
        transform: translateX(0) translateY(100px);
    }
    
    .toast-notification.show {
        transform: translateX(0) translateY(0);
    }
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* Selection */
::selection {
    background: rgba(59, 130, 246, 0.2);
    color: var(--text);
}

[data-theme="dark"] ::selection {
    background: rgba(96, 165, 250, 0.3);
}
