/* ===================================
   Link Card Generator - Premium UI
   World-class UIUX Design
   =================================== */

/* CSS Variables */
:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --secondary: #64748b;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-tertiary: #94a3b8;
    
    --border-color: #e2e8f0;
    --border-focus: #6366f1;
    
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    
    --transition-fast: 150ms ease;
    --transition-base: 200ms ease;
    --transition-slow: 300ms ease;
    
    --font-sans: 'Inter', 'Noto Sans JP', -apple-system, BlinkMacSystemFont, sans-serif;
}

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

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    background: var(--bg-secondary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

/* App Container */
.app-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header */
.header {
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(8px);
    background: rgba(255, 255, 255, 0.95);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text-primary);
}

.logo-icon {
    width: 32px;
    height: 32px;
    color: var(--primary);
}

.logo-text {
    font-size: 18px;
    font-weight: 600;
    letter-spacing: -0.02em;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: var(--radius-md);
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    transition: all var(--transition-fast);
}

.nav-link:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.nav-link svg {
    width: 18px;
    height: 18px;
}

/* Main */
.main {
    flex: 1;
    padding: 40px 24px 80px;
    max-width: 640px;
    margin: 0 auto;
    width: 100%;
}

/* Hero */
.hero {
    text-align: center;
    margin-bottom: 40px;
}

.hero-badge {
    display: inline-block;
    padding: 6px 14px;
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    color: white;
    font-size: 12px;
    font-weight: 600;
    border-radius: 100px;
    margin-bottom: 16px;
    letter-spacing: 0.02em;
}

.hero-title {
    font-size: 32px;
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.3;
    margin-bottom: 12px;
    background: linear-gradient(135deg, var(--text-primary), var(--primary-dark));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 15px;
    color: var(--text-secondary);
    max-width: 400px;
    margin: 0 auto;
}

.sp-only {
    display: none;
}

@media (max-width: 480px) {
    .sp-only {
        display: inline;
    }
    .hero-title {
        font-size: 26px;
    }
}

/* Card Generator */
.card-generator {
    background: var(--bg-primary);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.generator-form {
    padding: 32px;
}

/* Form Section */
.form-section {
    margin-bottom: 32px;
}

.form-section:last-of-type {
    margin-bottom: 24px;
}

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

.step-number {
    width: 28px;
    height: 28px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 600;
    flex-shrink: 0;
}

.form-label {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
}

.toggle-advanced {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 6px 12px;
    background: var(--bg-tertiary);
    border: none;
    border-radius: var(--radius-md);
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.toggle-advanced:hover {
    background: var(--border-color);
    color: var(--text-primary);
}

.toggle-advanced svg {
    width: 16px;
    height: 16px;
    transition: transform var(--transition-fast);
}

.toggle-advanced.active svg {
    transform: rotate(180deg);
}

/* Form Group */
.form-group {
    margin-bottom: 20px;
}

.form-group:last-child {
    margin-bottom: 0;
}

.input-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.required {
    color: var(--danger);
}

.input-hint {
    font-size: 12px;
    color: var(--text-tertiary);
    margin-top: 6px;
}

/* Form Input */
.form-input,
.form-textarea {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 2px solid transparent;
    border-radius: var(--radius-md);
    font-size: 15px;
    font-family: inherit;
    color: var(--text-primary);
    transition: all var(--transition-fast);
}

.form-input:hover,
.form-textarea:hover {
    background: var(--bg-tertiary);
}

.form-input:focus,
.form-textarea:focus {
    outline: none;
    background: var(--bg-primary);
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: var(--text-tertiary);
}

.form-textarea {
    resize: vertical;
    min-height: 80px;
}

.input-footer {
    display: flex;
    justify-content: flex-end;
    margin-top: 6px;
}

.char-count {
    font-size: 12px;
    color: var(--text-tertiary);
}

/* Image Upload */
.image-upload-area {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-lg);
    padding: 40px 24px;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-fast);
    background: var(--bg-secondary);
}

.image-upload-area:hover,
.image-upload-area.dragover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.04);
}

.upload-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 16px;
    background: var(--bg-tertiary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.upload-icon svg {
    width: 24px;
    height: 24px;
    color: var(--text-secondary);
}

.upload-text {
    font-size: 15px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.upload-subtext {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.upload-link {
    color: var(--primary);
    font-weight: 500;
}

.upload-hint {
    font-size: 12px;
    color: var(--text-tertiary);
}

/* Preview Container */
.preview-container {
    margin-top: 16px;
}

.preview-image-wrapper {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--bg-tertiary);
}

.preview-image-wrapper img {
    width: 100%;
    height: auto;
    display: block;
}

.preview-actions {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    gap: 8px;
}

.preview-btn {
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-fast);
    box-shadow: var(--shadow-md);
}

.preview-btn svg {
    width: 18px;
    height: 18px;
    color: var(--text-secondary);
}

.preview-btn:hover {
    background: white;
    transform: scale(1.05);
}

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

.preview-btn-danger:hover svg {
    color: var(--danger);
}

/* Background Type Selector */
.bg-type-selector {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.bg-type-option {
    cursor: pointer;
}

.bg-type-option input {
    display: none;
}

.bg-type-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 16px 12px;
    background: var(--bg-secondary);
    border: 2px solid transparent;
    border-radius: var(--radius-md);
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all var(--transition-fast);
}

.bg-type-option input:checked + .bg-type-label {
    background: rgba(99, 102, 241, 0.08);
    border-color: var(--primary);
    color: var(--primary);
}

.bg-type-icon {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
}

.solid-icon {
    background: #ffffff;
    border: 1px solid var(--border-color);
}

.gradient-icon {
    background: linear-gradient(135deg, #667eea, #764ba2);
}

.image-icon {
    background: linear-gradient(135deg, #e2e8f0, #94a3b8);
    position: relative;
}

.image-icon::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 4px;
    right: 4px;
    height: 8px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 2px;
}

/* Color Picker */
.color-picker-wrapper {
    display: flex;
    gap: 8px;
    align-items: center;
}

.color-picker {
    width: 44px;
    height: 44px;
    padding: 2px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    background: transparent;
}

.color-picker::-webkit-color-swatch-wrapper {
    padding: 0;
}

.color-picker::-webkit-color-swatch {
    border: none;
    border-radius: 4px;
}

.color-text {
    flex: 1;
    padding: 10px 12px;
    background: var(--bg-secondary);
    border: 2px solid transparent;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-family: monospace;
    text-transform: uppercase;
}

.color-text:focus {
    outline: none;
    border-color: var(--primary);
}

.color-presets {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    flex-wrap: wrap;
}

.color-preset {
    width: 32px;
    height: 32px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.color-preset:hover {
    transform: scale(1.1);
    border-color: var(--primary);
}

/* Gradient Settings */
.gradient-colors {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.gradient-color-item label {
    display: block;
    font-size: 12px;
    color: var(--text-tertiary);
    margin-bottom: 6px;
}

.gradient-presets {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.gradient-preset {
    width: 40px;
    height: 40px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.gradient-preset:hover {
    transform: scale(1.1);
    border-color: var(--primary);
}

/* Range Slider */
.range-slider {
    width: 100%;
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: 3px;
    outline: none;
    -webkit-appearance: none;
}

.range-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background: var(--primary);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: var(--shadow-md);
    transition: transform var(--transition-fast);
}

.range-slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
}

/* Background Image Upload */
.bg-image-upload {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.bg-image-upload:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.04);
}

.bg-image-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
}

.bg-image-placeholder svg {
    width: 32px;
    height: 32px;
}

.bg-image-placeholder span {
    font-size: 13px;
}

.bg-image-preview {
    position: relative;
}

.bg-image-preview img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: var(--radius-sm);
}

.bg-image-remove {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    background: rgba(0, 0, 0, 0.6);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.bg-image-remove svg {
    width: 14px;
    height: 14px;
    color: white;
}

.bg-image-remove:hover {
    background: var(--danger);
}

/* Advanced Settings */
.advanced-settings {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

/* Generate Button */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 15px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.btn-generate {
    width: 100%;
    padding: 16px 24px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    border-radius: var(--radius-lg);
    font-size: 16px;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4);
}

.btn-generate:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
}

.btn-generate:active {
    transform: translateY(0);
}

.btn-icon {
    display: flex;
    transition: transform var(--transition-fast);
}

.btn-generate:hover .btn-icon {
    transform: translateX(4px);
}

.btn-icon svg {
    width: 20px;
    height: 20px;
}

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

.btn-primary:hover {
    background: var(--primary-dark);
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
}

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

/* Result Section */
.result-section {
    padding: 32px;
    text-align: center;
}

.result-header {
    margin-bottom: 24px;
}

.result-success-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #10b981, #059669);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.result-success-icon svg {
    width: 28px;
    height: 28px;
    color: white;
}

.result-header h2 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 8px;
}

.result-header p {
    font-size: 14px;
    color: var(--text-secondary);
}

/* Card Preview */
.result-preview {
    margin-bottom: 24px;
}

.card-preview {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    text-align: left;
    max-width: 400px;
    margin: 0 auto;
}

.card-preview-image {
    width: 100%;
    aspect-ratio: 1.91 / 1;
    object-fit: cover;
}

.card-preview-content {
    padding: 16px;
}

.card-preview-title {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-preview-description {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-preview-url {
    font-size: 12px;
    color: var(--text-tertiary);
}

/* URL Copy Field */
.result-url {
    margin-bottom: 24px;
    text-align: left;
}

.url-copy-field {
    display: flex;
    gap: 8px;
}

.url-copy-field .form-input {
    flex: 1;
    font-size: 13px;
    padding: 10px 14px;
}

.btn-copy {
    background: var(--primary);
    color: white;
    padding: 10px 16px;
    white-space: nowrap;
}

.btn-copy:hover {
    background: var(--primary-dark);
}

.btn-copy svg {
    width: 16px;
    height: 16px;
}

/* Result Actions */
.result-actions {
    display: flex;
    justify-content: center;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-base);
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.modal-content {
    position: relative;
    background: var(--bg-primary);
    border-radius: var(--radius-xl);
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transform: scale(0.95);
    transition: transform var(--transition-base);
}

.modal.active .modal-content {
    transform: scale(1);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    font-size: 18px;
    font-weight: 600;
}

.modal-close {
    width: 36px;
    height: 36px;
    background: var(--bg-tertiary);
    border: none;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.modal-close:hover {
    background: var(--border-color);
}

.modal-close svg {
    width: 18px;
    height: 18px;
    color: var(--text-secondary);
}

.modal-body {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 20px 24px;
    border-top: 1px solid var(--border-color);
}

/* Crop Container */
.crop-container {
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: 16px;
}

.crop-container img {
    max-width: 100%;
    display: block;
}

.crop-controls {
    display: flex;
    justify-content: center;
    gap: 8px;
}

.crop-btn {
    width: 44px;
    height: 44px;
    background: var(--bg-secondary);
    border: none;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.crop-btn:hover {
    background: var(--bg-tertiary);
}

.crop-btn svg {
    width: 20px;
    height: 20px;
    color: var(--text-secondary);
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-base);
}

.loading-overlay.active {
    opacity: 1;
    visibility: visible;
}

.loading-spinner {
    text-align: center;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 3px solid var(--bg-tertiary);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 0 auto 16px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-spinner p {
    font-size: 14px;
    color: var(--text-secondary);
}

/* Toast */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 3000;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.toast {
    background: var(--text-primary);
    color: white;
    padding: 14px 20px;
    border-radius: var(--radius-md);
    font-size: 14px;
    box-shadow: var(--shadow-xl);
    animation: slideIn 0.3s ease;
}

.toast.success {
    background: var(--success);
}

.toast.error {
    background: var(--danger);
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Footer */
.footer {
    padding: 24px;
    text-align: center;
    font-size: 13px;
    color: var(--text-tertiary);
}

/* Responsive */
@media (max-width: 640px) {
    .main {
        padding: 24px 16px 60px;
    }
    
    .generator-form,
    .result-section {
        padding: 24px;
    }
    
    .hero {
        margin-bottom: 24px;
    }
    
    .hero-title {
        font-size: 24px;
    }
    
    .gradient-colors {
        grid-template-columns: 1fr;
    }
    
    .toast-container {
        left: 16px;
        right: 16px;
        bottom: 16px;
    }
}

/* Cropper.js Overrides */
.cropper-view-box,
.cropper-face {
    border-radius: 0;
}

.cropper-line {
    background-color: var(--primary);
}

.cropper-point {
    background-color: var(--primary);
    width: 10px;
    height: 10px;
}

.cropper-point.point-se {
    width: 10px;
    height: 10px;
}

/* Utility Classes for JS Toggles (Fix for mobile view) */
.hidden {
    display: none !important;
}

.visible {
    display: block !important;
}

/* Ensure touch targets are large enough on mobile */
.toggle-advanced {
    min-height: 44px;
    display: flex;
    align-items: center;
}

/* ===================================
   Cushion Page Toggle Switch
   =================================== */

/* クッションページトグルグループ */
.cushion-toggle-group {
    margin-bottom: 20px;
}

.cushion-toggle-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.cushion-toggle-wrapper .input-label {
    margin-bottom: 0;
    flex: 1;
}

/* トグルスイッチ */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 52px;
    height: 28px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--border-color);
    transition: all var(--transition-fast);
    border-radius: 28px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: all var(--transition-fast);
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.toggle-switch input:checked + .toggle-slider {
    background-color: var(--primary);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(24px);
}

.toggle-switch input:focus + .toggle-slider {
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

/* クッションページ無効時のスタイル */
.cushion-disabled #ctaTextGroup,
.cushion-disabled #advancedSettings,
.cushion-disabled .toggle-advanced {
    opacity: 0.5;
    pointer-events: none;
}

/* モバイル対応 */
@media (max-width: 480px) {
    .cushion-toggle-wrapper {
        flex-wrap: wrap;
    }
    
    .toggle-switch {
        min-width: 52px;
    }
}
