/**
 * Professional Design Enhancements
 * Design principles borrowed from MIT Technology Review and BTQ
 * Applied to our existing black/white accessibility theme
 */

/* ========================================
 * PRINCIPLE 1: Generous Vertical Rhythm
 * Both sites use substantial spacing between sections
 * ======================================== */

.section-breathing-room {
    padding: 5rem 0;
}

@media (min-width: 60rem) {
    .section-breathing-room {
        padding: 8rem 0;
    }
}

/* ========================================
 * PRINCIPLE 2: Strong Visual Hierarchy
 * Large, bold headlines that command attention
 * ======================================== */

.hero-headline {
    font-size: clamp(2.5rem, 8vw, 5.5rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: 1.5rem;
}

.section-headline {
    font-size: clamp(1.75rem, 4vw, 3rem);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 3rem;
}

/* ========================================
 * PRINCIPLE 3: Smooth Hover Interactions
 * Subtle transforms and transitions on interactive elements
 * ======================================== */

.interactive-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.interactive-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
}

.interactive-button {
    transition: transform 0.2s ease;
}

.interactive-button:hover {
    transform: translateY(-2px);
}

/* ========================================
 * PRINCIPLE 4: Clear Content Containers
 * Well-defined content areas with proper padding
 * ======================================== */

.content-container {
    max-width: 75rem;
    margin: 0 auto;
    padding: 0 1.5rem;
}

@media (min-width: 48rem) {
    .content-container {
        padding: 0 3rem;
    }
}

@media (min-width: 64rem) {
    .content-container {
        padding: 0 5rem;
    }
}

/* ========================================
 * PRINCIPLE 5: Readable Line Lengths
 * Optimal reading width for body text
 * ======================================== */

.prose-optimal {
    max-width: 65ch;
    margin-left: auto;
    margin-right: auto;
}

/* ========================================
 * PRINCIPLE 6: Subtle Border Treatments
 * Use borders to create visual separation without harshness
 * ======================================== */

.bordered-section {
    border-top: 1px solid var(--border-subtle);
    padding-top: 3rem;
}

.bordered-card {
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    padding: 2rem;
}

/* ========================================
 * PRINCIPLE 7: Responsive Grid Patterns
 * Flexible grid that adapts to screen size
 * ======================================== */

.auto-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr));
    gap: 2rem;
}

.auto-grid-narrow {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr));
    gap: 1.5rem;
}

/* ========================================
 * PRINCIPLE 8: Consistent Button Sizing
 * Touch-friendly buttons with proper padding
 * ======================================== */

.button-standard {
    padding: 0.875rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 6px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.button-large {
    padding: 1.125rem 2.5rem;
    font-size: 1.125rem;
    min-height: 52px;
}

/* ========================================
 * PRINCIPLE 9: Visual Feedback on Focus
 * Clear indication of focused elements
 * ======================================== */

*:focus-visible {
    outline: 3px solid currentColor;
    outline-offset: 3px;
}

/* ========================================
 * PRINCIPLE 10: Progressive Enhancement
 * Smooth animations only where they add value
 * ======================================== */

.fade-in-view {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in-view.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Disable animations for accessibility */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .fade-in-view {
        opacity: 1;
        transform: none;
    }
}

/* ========================================
 * PRINCIPLE 11: Minimal Border Radius
 * Subtle rounding that looks modern without being trendy
 * ======================================== */

.rounded-subtle {
    border-radius: 4px;
}

.rounded-moderate {
    border-radius: 8px;
}

.rounded-prominent {
    border-radius: 12px;
}

/* ========================================
 * PRINCIPLE 12: Proper Loading States
 * Visual feedback during content loading
 * ======================================== */

.skeleton-loader {
    background: linear-gradient(
        90deg,
        var(--bg-secondary) 0%,
        var(--bg-tertiary) 50%,
        var(--bg-secondary) 100%
    );
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.5s ease-in-out infinite;
    border-radius: 4px;
}

@keyframes skeleton-shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton-text {
    height: 1em;
    margin: 0.5rem 0;
}

.skeleton-heading {
    height: 2em;
    width: 70%;
    margin: 1rem 0;
}

/* ========================================
 * PRINCIPLE 13: Consistent Spacing Scale
 * Harmonious spacing throughout the design
 * ======================================== */

.spacing-xs { margin: 0.5rem 0; }
.spacing-sm { margin: 1rem 0; }
.spacing-md { margin: 2rem 0; }
.spacing-lg { margin: 3rem 0; }
.spacing-xl { margin: 5rem 0; }

.gap-xs { gap: 0.5rem; }
.gap-sm { gap: 1rem; }
.gap-md { gap: 2rem; }
.gap-lg { gap: 3rem; }
.gap-xl { gap: 5rem; }
