/* ==================== CSS Variables & Reset ==================== */
:root {
    --color-bg: #ffffff;
    --color-bg-alt: #f7f8fa;
    --color-bg-elevated: #ffffff;
    --color-border: #e4e7eb;
    --color-text: #0f172a;
    --color-text-secondary: #475569;
    --color-text-muted: #94a3b8;
    --color-primary: #FE2C55;
    --color-primary-hover: #e0264c;
    --color-secondary: #25F4EE;
    --color-accent: #7c3aed;
    --color-success: #10b981;
    --color-error: #ef4444;
    --color-warning: #f59e0b;
    --gradient-primary: linear-gradient(135deg, #25F4EE 0%, #FE2C55 100%);
    --gradient-hero: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%);
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
    --shadow-lg: 0 12px 32px rgba(0,0,0,0.10);
    --shadow-xl: 0 24px 64px rgba(0,0,0,0.14);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 28px;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-heading: 'Outfit', 'Inter', sans-serif;
    --header-height: 68px;
    --container-max: 1200px;
}

[data-theme="dark"] {
    --color-bg: #0a0a0f;
    --color-bg-alt: #12121a;
    --color-bg-elevated: #1a1a26;
    --color-border: #2a2a38;
    --color-text: #f1f5f9;
    --color-text-secondary: #cbd5e1;
    --color-text-muted: #64748b;
    --color-primary: #FE2C55;
    --color-primary-hover: #ff4569;
    --color-secondary: #25F4EE;
    --color-accent: #a78bfa;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.4);
    --shadow-lg: 0 12px 32px rgba(0,0,0,0.5);
    --shadow-xl: 0 24px 64px rgba(0,0,0,0.6);
}

*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    background-color: var(--color-bg);
    color: var(--color-text);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
    transition: background-color 0.3s ease, color 0.3s ease;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
    color: inherit;
}

input, select, textarea {
    font-family: inherit;
    font-size: inherit;
}

/* ==================== Container ==================== */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 20px;
}

/* ==================== Header ==================== */
.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--color-bg-elevated);
    border-bottom: 1px solid var(--color-border);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--header-height);
    gap: 16px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.logo-text {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.25rem;
    color: var(--color-text);
    letter-spacing: -0.5px;
}

.main-nav {
    display: flex;
    align-items: center;
}

.nav-list {
    display: flex;
    align-items: center;
    gap: 4px;
    list-style: none;
}

.nav-item {
    position: relative;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 8px 14px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--color-text-secondary);
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
    white-space: nowrap;
}

.nav-link:hover, .nav-link:focus {
    color: var(--color-text);
    background: var(--color-bg-alt);
}

.has-dropdown:hover > .mega-dropdown,
.has-dropdown:focus-within > .mega-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.mega-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 520px;
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-xl);
    padding: 12px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
    z-index: 100;
}

.dropdown-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
}

.dropdown-item {
    display: flex;
    flex-direction: column;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    transition: background 0.15s ease;
}

.dropdown-item:hover {
    background: var(--color-bg-alt);
}

.dropdown-item-title {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--color-text);
}

.dropdown-item-desc {
    font-size: 0.75rem;
    color: var(--color-text-muted);
    margin-top: 2px;
}

.dropdown-item.active .dropdown-item-title {
    color: var(--color-primary);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
    color: var(--color-text-secondary);
    transition: all 0.2s ease;
}

.theme-toggle:hover {
    background: var(--color-bg-alt);
    color: var(--color-text);
}

.icon-moon { display: none; }
[data-theme="dark"] .icon-sun { display: none; }
[data-theme="dark"] .icon-moon { display: block; }

.menu-toggle, .nav-close {
    display: none;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
    color: var(--color-text);
}

/* ==================== Breadcrumb ==================== */
.breadcrumb {
    padding: 12px 0;
    background: var(--color-bg-alt);
    border-bottom: 1px solid var(--color-border);
}

.breadcrumb-list {
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
    font-size: 0.8rem;
    color: var(--color-text-muted);
    flex-wrap: wrap;
}

.breadcrumb-item a {
    color: var(--color-text-secondary);
    transition: color 0.2s ease;
}

.breadcrumb-item a:hover {
    color: var(--color-primary);
}

.breadcrumb-item.active {
    color: var(--color-text);
    font-weight: 500;
}

.breadcrumb-sep {
    color: var(--color-text-muted);
}

/* ==================== Hero ==================== */
.hero {
    padding: 48px 0 64px;
    background: var(--color-bg);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -10%;
    width: 60%;
    height: 120%;
    background: radial-gradient(ellipse, rgba(37,244,238,0.08) 0%, transparent 60%);
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    top: -30%;
    right: -10%;
    width: 50%;
    height: 100%;
    background: radial-gradient(ellipse, rgba(254,44,85,0.08) 0%, transparent 60%);
    pointer-events: none;
}

.hero-content {
    text-align: center;
    max-width: 720px;
    margin: 0 auto 40px;
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: inline-block;
    padding: 6px 16px;
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--color-text-secondary);
    margin-bottom: 20px;
}

.hero-title {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 5vw, 3.25rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -1.5px;
    margin-bottom: 16px;
}

.gradient-text {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.1rem;
    color: var(--color-text-secondary);
    line-height: 1.6;
    max-width: 560px;
    margin: 0 auto;
}

/* ==================== Tool Card ==================== */
.tool-card {
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    padding: 36px;
    box-shadow: var(--shadow-lg);
    max-width: 860px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.tool-header {
    text-align: center;
    margin-bottom: 28px;
}

.tool-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.tool-subtitle {
    font-size: 0.95rem;
    color: var(--color-text-secondary);
}

/* Upload Area */
.upload-area {
    border: 2px dashed var(--color-border);
    border-radius: var(--radius-lg);
    padding: 48px 24px;
    text-align: center;
    cursor: pointer;
    transition: all 0.25s ease;
    background: var(--color-bg-alt);
}

.upload-area:hover, .upload-area.dragover {
    border-color: var(--color-primary);
    background: rgba(254,44,85,0.04);
}

.upload-icon {
    margin-bottom: 16px;
}

.upload-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 4px;
}

.upload-subtext {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
}

.upload-link {
    color: var(--color-primary);
    font-weight: 600;
}

.upload-formats {
    font-size: 0.78rem;
    color: var(--color-text-muted);
    margin-top: 12px;
}

/* File Info */
.file-info {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    margin-top: 20px;
}

.file-preview {
    width: 64px;
    height: 64px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    background: var(--color-bg);
    flex-shrink: 0;
    border: 1px solid var(--color-border);
}

.file-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.file-details {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
    min-width: 0;
}

.file-name {
    font-weight: 600;
    font-size: 0.9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-meta {
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

.btn-remove {
    align-self: flex-start;
    font-size: 0.8rem;
    color: var(--color-error);
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    transition: background 0.2s ease;
}

.btn-remove:hover {
    background: rgba(239,68,68,0.1);
}

/* Error Message */
.error-message {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: rgba(239,68,68,0.1);
    border: 1px solid rgba(239,68,68,0.3);
    border-radius: var(--radius-md);
    color: var(--color-error);
    font-size: 0.875rem;
    margin-top: 16px;
}

/* Options Grid */
.options-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 24px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-text-secondary);
}

.form-input {
    padding: 10px 14px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-bg);
    color: var(--color-text);
    font-size: 0.9rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(254,44,85,0.1);
}

.dim-inputs {
    display: flex;
    align-items: center;
    gap: 8px;
}

.dim-x {
    color: var(--color-text-muted);
    font-weight: 600;
}

/* Custom Select */
.custom-select {
    position: relative;
}

.select-trigger {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-bg);
    color: var(--color-text);
    font-size: 0.9rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.custom-select.open .select-trigger {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(254,44,85,0.1);
}

.select-trigger svg {
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.custom-select.open .select-trigger svg {
    transform: rotate(180deg);
}

.select-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    list-style: none;
    max-height: 240px;
    overflow-y: auto;
    z-index: 50;
    opacity: 0;
    visibility: hidden;
    transform: translateY(4px);
    transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
}

.custom-select.open .select-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.select-dropdown li {
    padding: 10px 14px;
    font-size: 0.875rem;
    cursor: pointer;
    transition: background 0.15s ease;
    color: var(--color-text);
}

.select-dropdown li:hover {
    background: var(--color-bg-alt);
}

.select-dropdown li.selected {
    background: rgba(254,44,85,0.06);
    color: var(--color-primary);
    font-weight: 600;
}

/* Radio Group */
.radio-group {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.875rem;
    cursor: pointer;
    color: var(--color-text-secondary);
}

.radio-label input {
    display: none;
}

.radio-custom {
    width: 18px;
    height: 18px;
    border: 2px solid var(--color-border);
    border-radius: 50%;
    position: relative;
    transition: border-color 0.2s ease;
}

.radio-label input:checked + .radio-custom {
    border-color: var(--color-primary);
}

.radio-label input:checked + .radio-custom::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--color-primary);
}

/* Range */
.form-range {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    background: var(--color-border);
    border-radius: 3px;
    outline: none;
}

.form-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    background: var(--color-primary);
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.15s ease;
}

.form-range::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: var(--color-primary);
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

/* Submit Button */
.btn-submit {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 24px;
    background: var(--gradient-primary);
    color: #ffffff;
    font-size: 1rem;
    font-weight: 700;
    border-radius: var(--radius-md);
    margin-top: 28px;
    transition: opacity 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
    box-shadow: 0 4px 16px rgba(254,44,85,0.3);
}

.btn-submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
}

.btn-submit:disabled .btn-text {
    opacity: 0.7;
}

.btn-spinner {
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-spinner svg {
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ==================== Result Card ==================== */
.result-card {
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    padding: 36px;
    box-shadow: var(--shadow-lg);
    max-width: 860px;
    margin: 24px auto 0;
    scroll-margin-top: 90px;
}

.result-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 12px;
}

.result-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
}

.result-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    background: rgba(16,185,129,0.1);
    color: var(--color-success);
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 600;
}

.result-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

.result-preview {
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    overflow: hidden;
}

.result-preview img {
    max-width: 100%;
    max-height: 300px;
    border-radius: var(--radius-sm);
    object-fit: contain;
}

.result-info {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.result-stat {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    background: var(--color-bg-alt);
    border-radius: var(--radius-sm);
    border: 1px solid var(--color-border);
}

.stat-label {
    font-size: 0.825rem;
    color: var(--color-text-muted);
    font-weight: 500;
}

.stat-value {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--color-text);
}

.result-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.btn-download, .btn-copy, .btn-resize-another {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: var(--radius-md);
    transition: all 0.2s ease;
    flex: 1;
    justify-content: center;
    min-width: 140px;
}

.btn-download {
    background: var(--color-primary);
    color: #ffffff;
}

.btn-copy {
    background: var(--color-bg-alt);
    color: var(--color-text);
    border: 1px solid var(--color-border);
}

.btn-resize-another {
    background: transparent;
    color: var(--color-text-secondary);
    border: 1px solid var(--color-border);
}

/* Post Actions */
.post-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--color-border);
    flex-wrap: wrap;
}

.share-section {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.post-action-label {
    font-size: 0.825rem;
    color: var(--color-text-muted);
    font-weight: 500;
}

.share-buttons {
    display: flex;
    gap: 8px;
}

.share-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    background: var(--color-bg-alt);
    color: var(--color-text-secondary);
    border: 1px solid var(--color-border);
    transition: all 0.2s ease;
}

.feedback-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    font-size: 0.825rem;
    font-weight: 600;
    color: var(--color-text-secondary);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}

/* ==================== SEO Content ==================== */
.seo-content {
    padding: 64px 0;
    background: var(--color-bg-alt);
}

.seo-text {
    max-width: 800px;
    margin: 0 auto;
}

.seo-text h2 {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 20px;
    letter-spacing: -0.5px;
}

.seo-text p {
    font-size: 1rem;
    color: var(--color-text-secondary);
    line-height: 1.8;
    margin-bottom: 16px;
}

/* ==================== Related Tools ==================== */
.related-tools {
    padding: 48px 0;
    background: var(--color-bg);
}

.section-title-small {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 24px;
    text-align: center;
}

.related-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.related-link {
    padding: 8px 16px;
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: 100px;
    font-size: 0.825rem;
    font-weight: 500;
    color: var(--color-text-secondary);
    transition: all 0.2s ease;
}

/* ==================== Features ==================== */
.features {
    padding: 64px 0;
    background: var(--color-bg-alt);
}

.section-header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 48px;
}

.section-tag {
    display: inline-block;
    padding: 4px 14px;
    background: rgba(254,44,85,0.1);
    color: var(--color-primary);
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.section-title {
    font-family: var(--font-heading);
    font-size: clamp(1.5rem, 3vw, 2.25rem);
    font-weight: 800;
    letter-spacing: -1px;
    margin-bottom: 12px;
}

.section-desc {
    font-size: 1rem;
    color: var(--color-text-secondary);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.feature-card {
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 28px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    background: var(--gradient-primary);
    color: #ffffff;
    margin-bottom: 16px;
}

.feature-card h3 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.feature-card p {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
    line-height: 1.6;
}

/* ==================== How It Works ==================== */
.how-it-works {
    padding: 64px 0;
    background: var(--color-bg);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.step-card {
    text-align: center;
    padding: 32px 24px;
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    position: relative;
}

.step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: var(--gradient-primary);
    color: #ffffff;
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 800;
    border-radius: 50%;
    margin: 0 auto 16px;
}

.step-card h3 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.step-card p {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
    line-height: 1.6;
}

/* ==================== FAQ ==================== */
.faq {
    padding: 64px 0;
    background: var(--color-bg-alt);
}

.faq-list {
    max-width: 760px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq-item {
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: border-color 0.2s ease;
}

.faq-item.active {
    border-color: var(--color-primary);
}

.faq-question {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 24px;
    font-size: 1rem;
    font-weight: 600;
    text-align: left;
    color: var(--color-text);
    transition: background 0.2s ease;
}

.faq-icon {
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.faq-item.active .faq-icon {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    padding: 0 24px;
}

.faq-item.active .faq-answer {
    max-height: 300px;
    padding-bottom: 18px;
}

.faq-answer p {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
    line-height: 1.7;
}

/* ==================== CTA ==================== */
.cta {
    padding: 64px 0;
    background: var(--color-bg);
}

.cta-box {
    background: var(--gradient-hero);
    border-radius: var(--radius-xl);
    padding: 56px 36px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

[data-theme="dark"] .cta-box {
    background: linear-gradient(135deg, #1a1a26 0%, #2a1a3e 100%);
}

.cta-box::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -20%;
    width: 80%;
    height: 200%;
    background: radial-gradient(ellipse, rgba(37,244,238,0.15) 0%, transparent 50%);
}

.cta-box::after {
    content: '';
    position: absolute;
    bottom: -50%;
    right: -20%;
    width: 80%;
    height: 200%;
    background: radial-gradient(ellipse, rgba(254,44,85,0.15) 0%, transparent 50%);
}

.cta-title {
    font-family: var(--font-heading);
    font-size: clamp(1.5rem, 3vw, 2.25rem);
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 12px;
    position: relative;
    z-index: 1;
    letter-spacing: -0.5px;
}

.cta-desc {
    font-size: 1rem;
    color: rgba(255,255,255,0.8);
    max-width: 520px;
    margin: 0 auto 28px;
    position: relative;
    z-index: 1;
}

.cta-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 13px 28px;
    font-size: 0.95rem;
    font-weight: 700;
    border-radius: var(--radius-md);
    transition: all 0.2s ease;
    min-width: 160px;
}

.btn-primary {
    background: #ffffff;
    color: #0f172a;
}

.btn-outline {
    background: transparent;
    color: #ffffff;
    border: 2px solid rgba(255,255,255,0.4);
}

/* ==================== Footer ==================== */
.site-footer {
    background: var(--color-bg-alt);
    border-top: 1px solid var(--color-border);
    padding: 56px 0 24px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 32px;
    margin-bottom: 40px;
}

.footer-brand .logo {
    margin-bottom: 16px;
}

.footer-desc {
    font-size: 0.875rem;
    color: var(--color-text-secondary);
    line-height: 1.6;
    max-width: 280px;
}

.footer-heading {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--color-text);
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer-links a {
    font-size: 0.825rem;
    color: var(--color-text-secondary);
    transition: color 0.2s ease;
}

.footer-bottom {
    border-top: 1px solid var(--color-border);
    padding-top: 24px;
}

.footer-legal {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 16px;
}

.footer-legal p {
    font-size: 0.825rem;
    color: var(--color-text-secondary);
    font-weight: 500;
}

.footer-legal-links {
    display: flex;
    gap: 16px;
}

.footer-legal-links a {
    font-size: 0.825rem;
    color: var(--color-text-secondary);
    transition: color 0.2s ease;
}

.disclaimer {
    font-size: 0.75rem;
    color: var(--color-text-muted);
    line-height: 1.6;
    max-width: 900px;
}

/* ==================== Cookie Banner ==================== */
.cookie-banner {
    position: fixed;
    bottom: 16px;
    left: 16px;
    right: 16px;
    max-width: 480px;
    margin: 0 auto;
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    padding: 20px;
    z-index: 2000;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from { transform: translateY(100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.cookie-content {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.cookie-text {
    font-size: 0.825rem;
    color: var(--color-text-secondary);
    line-height: 1.5;
}

.cookie-link {
    color: var(--color-primary);
    font-weight: 600;
}

.cookie-actions {
    display: flex;
    gap: 8px;
}

.btn-cookie {
    flex: 1;
    padding: 10px 16px;
    font-size: 0.825rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}

.btn-cookie.accept {
    background: var(--color-primary);
    color: #ffffff;
}

.btn-cookie.dismiss {
    background: var(--color-bg-alt);
    color: var(--color-text-secondary);
    border: 1px solid var(--color-border);
}

/* ==================== Toast ==================== */
.toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(80px);
    background: var(--color-text);
    color: var(--color-bg);
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 600;
    box-shadow: var(--shadow-xl);
    z-index: 3000;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

.toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* ==================== Hover Effects (Only for devices that support hover, e.g., desktop) ==================== */
@media (hover: hover) {
    .nav-link:hover, .nav-link:focus {
        color: var(--color-text);
        background: var(--color-bg-alt);
    }
    .dropdown-item:hover {
        background: var(--color-bg-alt);
    }
    .theme-toggle:hover {
        background: var(--color-bg-alt);
        color: var(--color-text);
    }
    .upload-area:hover, .upload-area.dragover {
        border-color: var(--color-primary);
        background: rgba(254,44,85,0.04);
    }
    .btn-remove:hover {
        background: rgba(239,68,68,0.1);
    }
    .select-trigger:hover {
        border-color: var(--color-text-muted);
    }
    .select-dropdown li:hover {
        background: var(--color-bg-alt);
    }
    .btn-submit:hover:not(:disabled) {
        transform: translateY(-1px);
        box-shadow: 0 6px 24px rgba(254,44,85,0.4);
    }
    .btn-download:hover {
        background: var(--color-primary-hover);
        transform: translateY(-1px);
    }
    .btn-copy:hover {
        background: var(--color-border);
    }
    .btn-resize-another:hover {
        background: var(--color-bg-alt);
    }
    .share-btn:hover {
        color: var(--color-primary);
        border-color: var(--color-primary);
        transform: translateY(-1px);
    }
    .feedback-btn:hover {
        color: var(--color-primary);
        border-color: var(--color-primary);
    }
    .related-link:hover {
        color: var(--color-primary);
        border-color: var(--color-primary);
        transform: translateY(-1px);
    }
    .feature-card:hover {
        transform: translateY(-4px);
        box-shadow: var(--shadow-lg);
    }
    .faq-question:hover {
        background: var(--color-bg-alt);
    }
    .btn-primary:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 24px rgba(0,0,0,0.2);
    }
    .btn-outline:hover {
        background: rgba(255,255,255,0.1);
        border-color: rgba(255,255,255,0.8);
        transform: translateY(-2px);
    }
    .btn-cookie.accept:hover {
        background: var(--color-primary-hover);
    }
    .btn-cookie.dismiss:hover {
        background: var(--color-border);
    }
    .footer-links a:hover {
        color: var(--color-primary);
    }
    .footer-legal-links a:hover {
        color: var(--color-primary);
    }
    .breadcrumb-item a:hover {
        color: var(--color-primary);
    }
    .form-range::-webkit-slider-thumb:hover {
        transform: scale(1.15);
    }
}

/* ==================== Responsive ==================== */
@media (max-width: 980px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr 1fr;
    }
    .footer-brand {
        grid-column: 1 / -1;
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }

    .main-nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 85%;
        max-width: 360px;
        height: 100vh;
        background: var(--color-bg-elevated);
        border-left: 1px solid var(--color-border);
        padding: 80px 20px 20px;
        flex-direction: column;
        align-items: flex-start;
        overflow-y: auto;
        transition: right 0.3s ease;
        z-index: 1100;
        box-shadow: var(--shadow-xl);
    }

    .main-nav.open {
        right: 0;
    }

    .nav-close {
        display: flex;
        position: absolute;
        top: 16px;
        right: 16px;
    }

    .nav-list {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
        width: 100%;
    }

    .nav-item {
        width: 100%;
    }

    .nav-link {
        width: 100%;
        justify-content: space-between;
        padding: 12px 14px;
    }

    .mega-dropdown {
        position: static;
        min-width: 100%;
        box-shadow: none;
        border: none;
        padding: 0 0 0 14px;
        opacity: 1;
        visibility: visible;
        transform: none;
        display: none;
    }

    .has-dropdown.open > .mega-dropdown {
        display: block;
    }

    .dropdown-grid {
        grid-template-columns: 1fr;
    }

    .hero {
        padding: 32px 0 48px;
    }

    .tool-card {
        padding: 24px 20px;
        border-radius: var(--radius-lg);
    }

    .options-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .result-card {
        padding: 24px 20px;
        border-radius: var(--radius-lg);
    }

    .result-body {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .result-actions {
        flex-direction: column;
    }

    .btn-download, .btn-copy, .btn-resize-another {
        width: 100%;
    }

    .post-actions {
        flex-direction: column;
        align-items: flex-start;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 24px;
    }

    .footer-legal {
        flex-direction: column;
        align-items: flex-start;
    }

    .cookie-banner {
        left: 12px;
        right: 12px;
        bottom: 12px;
    }
}

@media (max-width: 480px) {
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .hero-badge {
        font-size: 0.72rem;
    }

    .upload-area {
        padding: 32px 16px;
    }

    .cta-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }
}

/* Body scroll lock when nav open */
body.nav-open {
    overflow: hidden;
}

/* Nav overlay */
.nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1050;
}

.nav-overlay.show {
    display: block;
}

/* Print optimization */
@media print {
    .site-header, .breadcrumb, .cta, .site-footer, .cookie-banner, .post-actions {
        display: none;
    }
}