:root {
    /* Court Green - основной акцент (теннисный корт) */
    --color-primary: #2d8a4e;
    --color-primary-light: #3da863;

    /* Tennis Ball Yellow - вторичный акцент */
    --color-accent: #ccff00;
    --color-accent-muted: #b8e600;

    /* Clay Court Terracotta */
    --color-clay: #c45c3e;
    --color-clay-light: #d97a5e;

    /* Background and surfaces */
    --color-bg: #fafafa;
    --color-surface: #ffffff;
    --color-surface-elevated: #ffffff;

    /* Text colors */
    --color-text: #1a1a2e;
    --color-text-secondary: #4a4a5a;
    --color-text-muted: #6b6b7a;

    /* Borders and lines */
    --color-border: #e0e0e0;
    --color-border-light: #f0f0f0;

    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.12);
    --shadow-accent: 0 4px 20px rgba(45, 138, 78, 0.25);

    /* Typography */
    --font-primary: 'Segoe UI', system-ui, -apple-system, sans-serif;
    --font-heading: 'Georgia', 'Times New Roman', serif;

    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;
    --space-3xl: 4rem;
    --space-4xl: 7rem;

    /* Layout */
    --content-width: 75ch;
    --wide-width: 90ch;

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 250ms ease;
    --transition-slow: 400ms ease;

    /* Border radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 16px;
}


*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-primary);
    font-size: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
    line-height: 1.7;
    color: var(--color-text);
    background: var(--color-bg);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Focus styles for accessibility */
:focus-visible {
    outline: 3px solid var(--color-primary);
    outline-offset: 3px;
}

/* Skip link for accessibility */
.skip-link {
    position: absolute;
    top: -100%;
    left: var(--space-md);
    padding: var(--space-sm) var(--space-md);
    background: var(--color-primary);
    color: white;
    text-decoration: none;
    border-radius: var(--radius-sm);
    z-index: 1000;
    transition: top var(--transition-fast);
}

.skip-link:focus {
    top: var(--space-md);
}

.breadcrumbs {
    margin: 15px 0;
}


/* Navigation */
main nav {
    max-width: var(--wide-width);
    margin: 0 auto;
    padding: 5px 0;
}

img {
    width: 100%;
    height: auto;
}

/* Main content */
main {
    flex: 1;
    width: 100%;
    max-width: var(--wide-width);
    margin: 0 auto;
    padding: var(--space-4xl) var(--space-lg);
}


/* Hero image */
.hero-image {
    width: 100%;
    aspect-ratio: 13/9;
    object-fit: cover;
    display: block;
    border-bottom: 4px solid var(--color-primary);
}

/* Article content container */
.article-content {
    padding: var(--space-2xl) var(--space-xl);
    max-width: var(--content-width);
    margin: 0 auto;
}

@media (max-width: 768px) {
    .article-content {
        padding: var(--space-xl) var(--space-lg);
    }
}

/* Typography */
h1 {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 1.5rem + 2.5vw, 3.25rem);
    font-weight: 700;
    line-height: 1.15;
    color: var(--color-text);
    margin-bottom: var(--space-lg);
    letter-spacing: -0.02em;
}

h1::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-accent));
    margin-top: var(--space-lg);
    border-radius: 2px;
}

h2, .toc-wrap__title {
    font-family: var(--font-heading);
    font-size: clamp(1.5rem, 1.25rem + 1.25vw, 2.25rem);
    font-weight: 600;
    line-height: 1.25;
    color: var(--color-text);
    margin-top: var(--space-3xl);
    margin-bottom: var(--space-lg);
    padding-left: 15px;
    border-bottom: 4px solid var(--color-primary);
}

h3 {
    font-family: var(--font-heading);
    font-size: clamp(1.25rem, 1.1rem + 0.75vw, 1.625rem);
    font-weight: 600;
    line-height: 1.3;
    color: var(--color-text);
    margin-top: var(--space-2xl);
    margin-bottom: var(--space-md);
}



/* Links */
a {
    color: var(--color-primary);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
    transition: color var(--transition-fast), text-decoration-color var(--transition-fast);
}

a:hover {
    text-decoration-color: var(--color-accent);
}

/* Strong and emphasis */
strong {
    font-weight: 600;
    color: var(--color-text);
}

em {
    font-style: italic;
    color: var(--color-text);
}



li {
    margin-bottom: var(--space-sm);
    padding-left: var(--space-sm);
}

li::marker {
    color: var(--color-primary);
}


ol {
    counter-reset: list-counter;
}

ol li {
    counter-increment: list-counter;
}

ol li::marker {
    content: counter(list-counter) '.';
    font-weight: 600;
}

/* Nested lists */
li>ul,
li>ol {
    margin-top: var(--space-sm);
    margin-bottom: 0;
}

/* Blockquote */
blockquote {
    margin: var(--space-xl) 0;
    padding: var(--space-lg) var(--space-xl);
    background: linear-gradient(135deg, var(--color-surface-elevated) 0%, var(--color-border-light) 100%);
    border-left: 4px solid var(--color-clay);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    font-style: italic;
    color: var(--color-text);
    position: relative;
}

blockquote::before {
    content: '\201C';
    position: absolute;
    top: -10px;
    left: 15px;
    font-size: 4rem;
    font-family: var(--font-heading);
    color: var(--color-clay);
    opacity: 0.3;
    line-height: 1;
}

blockquote p {
    margin-bottom: 0;
    color: var(--color-text);
}

/* Figures and images */
figure {
    margin: var(--space-2xl) 0;
}

.article-image {
    width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.article-image:hover {
    transform: scale(1.01);
    box-shadow: var(--shadow-lg);
}

figcaption {
    margin-top: var(--space-sm);
    font-size: 0.875rem;
    color: var(--color-text-muted);
    text-align: center;
    font-style: italic;
}

/* Table of contents styling hint */
nav[aria-label="Contenido"] {
    background: var(--color-surface-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: var(--space-lg);
    margin: var(--space-xl) 0;
}

nav[aria-label="Contenido"] ul {
    list-style: none;
    padding-left: 0;
}

nav[aria-label="Contenido"] li {
    padding-left: 0;
}

nav[aria-label="Contenido"] a {
    display: block;
    padding: var(--space-xs) 0;
    text-decoration: none;
    transition: color var(--transition-fast), padding-left var(--transition-fast);
}

nav[aria-label="Contenido"] a:hover {
    padding-left: var(--space-sm);
}

/* Code blocks (if needed) */
code {
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 0.9em;
    background: var(--color-surface-elevated);
    padding: var(--space-xs) var(--space-sm);
    border-radius: var(--radius-sm);
    border: 1px solid var(--color-border);
}

pre {
    background: var(--color-surface-elevated);
    padding: var(--space-lg);
    border-radius: var(--radius-md);
    overflow-x: auto;
    margin: var(--space-lg) 0;
    border: 1px solid var(--color-border);
}

pre code {
    background: none;
    padding: 0;
    border: none;
}

/* Horizontal rule */
hr {
    border: none;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--color-border), transparent);
    margin: var(--space-2xl) 0;
}

/* FAQ section styling */
section[aria-label="FAQ"] h3 {
    background: var(--color-surface-elevated);
    padding: var(--space-md) var(--space-lg);
    margin-left: calc(-1 * var(--space-lg));
    margin-right: calc(-1 * var(--space-lg));
    border-radius: var(--radius-sm);
    transition: background var(--transition-base);
}

section[aria-label="FAQ"] h3:hover {
    background: var(--color-border-light);
}

/* Decorative court lines */
main::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg,
            var(--color-primary) 0%,
            var(--color-accent) 25%,
            var(--color-clay) 50%,
            var(--color-accent) 75%,
            var(--color-primary) 100%);
    z-index: 1000;
}



/* .footer-content {
    max-width: var(--content-width);
    margin: 0 auto;
} */

.disclaimer {
    font-size: 0.875rem;
    color: var(--color-text-muted);
    line-height: 1.6;
    text-align: center;
}

.disclaimer strong {
    color: var(--color-text-secondary);
}

/* Responsive adjustments */
@media (max-width: 640px) {
    main {
        padding: var(--space-2xl) var(--space-md);
    }

    .article-content {
        padding: var(--space-lg) var(--space-md);
    }


    blockquote {
        padding: var(--space-md) var(--space-lg);
        margin-left: 0;
        margin-right: 0;
    }

    blockquote::before {
        font-size: 2.5rem;
        top: -5px;
        left: 10px;
    }
}

/* Print styles */
@media print {

    header,
    footer,
    nav {
        display: none;
    }

    main::before {
        display: none;
    }

    article {
        box-shadow: none;
        border: 1px solid #ccc;
    }

    a {
        color: inherit;
        text-decoration: underline;
    }

    .hero-image {
        max-height: 200px;
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    html {
        scroll-behavior: auto;
    }
}

/* Selection styling */
::selection {
    background: var(--color-accent);
    color: var(--color-text);
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--color-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--color-border);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-primary);
}
 