:root {
    --primary-bg: #121614;
    --secondary-bg: #2F3E2D;
    --accent-color: #4E6B3C;
    --text-primary: #F4F4F4;
    --text-secondary: #F3F5F4;
    --border-color: rgba(255, 255, 255, 0.06);
    --shadow-color: rgba(78, 107, 60, 0.3);
    --overlay-bg: rgba(0, 0, 0, 0.7);

    --spacing-xs: 8px;
    --spacing-sm: 12px;
    --spacing-md: 20px;
    --spacing-lg: 40px;
    --spacing-xl: 60px;

    --font-xs: 14px;   
    --font-sm: 16px;   
    --font-md: 18px;   
    --font-lg: 24px;  
    --font-xl: 32px;   
    --font-2xl: 48px;  
    --font-3xl: 64px;  

    --border-radius: 30px;
    --border-radius-sm: 15px;
}

* {
    box-sizing: border-box;
    margin:0;
    padding:0;
}

body {
    font-family: 'Manrope', sans-serif;
    color:var(--text-primary);
    background-color:var(--primary-bg);
    line-height: 1.6;
}

h1 {
    font-size: var(--font-3xl);
    font-weight: 800;
    margin-bottom: var(--spacing-md);
    line-height: 1.2;
}

h2 {
    font-size: var(--font-xl);
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    line-height: 1.3;
}

h3 {
    font-size: var(--font-lg);
    font-weight: 500;
    margin-bottom: var(--spacing-xs);
    line-height: 1.4;
}

h4, p {
    font-size: var(--font-sm);
    font-weight: 400;
    margin-bottom: var(--spacing-xs);
    line-height: 1.5;
}

.certificate {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

.mainTitleCert{
    display:flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: var(--accent-color);
    font-size: var(--font-2xl); 
    font-weight: 700;
    margin: var(--spacing-xl) 0 var(--spacing-lg);
}

.success, .participation {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-lg);
    padding: var(--spacing-lg);
    max-width: 1400px; 
    margin: 0 auto;
}

.success > div, 
.participation > div {
    background-color: var(--secondary-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: 0 4px 12px var(--shadow-color);
    overflow: hidden;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: var(--spacing-md);
}

.success > div:hover,
.participation > div:hover {
    transform: translateY(-5px);
    background-color: var(--accent-color);
}

.success > div:hover h2,
.participation > div:hover h2 {
    color: var(--primary-bg);
}

.success img, 
.participation img {
    width: 100%;
    height: 200px;
    object-fit: cover; 
    margin-bottom: var(--spacing-sm);
    background-color: var(--primary-bg);
    border-radius: var(--border-radius-sm);
    border: 1px solid var(--border-color);
}

.success h3, .participation h3 {
    font-size: var(--font-sm);
    margin-bottom: var(--spacing-xs);
    color: var(--text-secondary); 
    font-weight: bold;
}

.success h2, .participation h2 {
    font-size: var(--font-md);
    font-weight: 600;
    color: var(--font-color); 
    margin-bottom: var(--spacing-xs);
}

.image-popup {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    justify-content: center;
    align-items: center;
}

.image-popup img {
    max-width: 90%;
    max-height: 90%;
    border-radius: var(--border-radius-sm);
    box-shadow: 0 4px 12px var(--shadow-color);
    animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.image-popup.show {
    display: flex;
}

@media screen and (max-width: 480px) {
    :root {
        --font-3xl: 32px;
        --font-2xl: 28px;
        --spacing-xs: 4px;
        --spacing-sm: 8px;
        --spacing-md: 12px;
        --spacing-lg: 20px;
        --spacing-xl: 30px;
    }

    .mainTitleCert { font-size: var(--font-xl); margin: var(--spacing-lg) 0; }
    .success, .participation { grid-template-columns: 1fr; }
}

@media screen and (min-width: 481px) and (max-width: 768px) {
    .success, .participation { grid-template-columns: repeat(2, 1fr); }
}

@media screen and (min-width: 769px) and (max-width: 1024px) {
    .success, .participation { grid-template-columns: repeat(2, 1fr); }
}

@media screen and (min-width: 2560px) {
    .success, .participation {
        grid-template-columns: repeat(4, 1fr);
        gap: var(--spacing-xl);
        max-width: 2400px;
        margin: 0 auto;
    }
    .success img, .participation img {
        height: 300px;
        max-width: 400px;
    }
}

.text-center { text-align: center; }
.flex-center { display: flex; justify-content: center; align-items: center; }
.container { max-width: 1400px; margin: 0 auto; padding: 0 var(--spacing-lg); }

html { scroll-behavior: smooth; }
