MediaWiki:Common.css: відмінності між версіями

Матеріал з Київський національний лінгвістичний університет
Перейти до навігації Перейти до пошуку
Немає опису редагування
Мітка: Ручний відкіт
Немає опису редагування
Рядок 1: Рядок 1:
/* Приветственный блок */
/* =============================================
  Головна сторінка — привітання та сітка проєктів
  ============================================= */
 
/* Привітальний блок */
.welcome-text {
.welcome-text {
     text-align: center;
     text-align: center;
Рядок 9: Рядок 13:
     color: white;
     color: white;
     border-radius: 12px;
     border-radius: 12px;
     box-shadow: 0 4px 20px rgba(0,61,130,0.15);
     box-shadow: 0 4px 20px rgba(0,61,130,0.18);
}
}


.welcome-text strong {
.welcome-text strong {
     color: #ffd700;
     color: #ffd700;
     font-size: 22px;
     font-size: 24px;
     font-weight: 600;
     font-weight: 700;
     display: block;
     display: block;
     margin-top: 10px;
     margin-top: 12px;
     font-style: normal;
     font-style: normal;
}
}


/* Заголовок секции */
/* Заголовок секції "Наші проєкти" */
.section-projects {
.section-projects {
     background: #003d82;
     background: #003d82;
     color: #ffd700;
     color: #ffd700;
     padding: 18px 25px;
     padding: 16px 24px;
     font-size: 20px;
     font-size: 20px;
     font-weight: 600;
     font-weight: 700;
     border-radius: 10px;
     border-radius: 10px;
     margin: 30px auto 20px;
     margin: 35px auto 25px;
     text-align: center;
     text-align: center;
     box-shadow: 0 2px 10px rgba(0,61,130,0.1);
     box-shadow: 0 3px 12px rgba(0,61,130,0.15);
     max-width: 1100px;
     max-width: 1100px;
}
}


.section-projects .emoji {
.section-projects .emoji {
     font-size: 26px;
     font-size: 28px;
     margin-right: 12px;
     margin-right: 10px;
    vertical-align: middle;
}
}


/* Сітка категорій 4 в ряд */
/* Сітка карток головний контейнер */
.category-grid-container {
.category-grid-container {
     display: grid;
     display: grid;
     grid-template-columns: repeat(4, 1fr);   /* саме 4 стовпці */
     grid-template-columns: repeat(4, 1fr);
     gap: 20px 16px;                         /* відстань між картками */
     gap: 20px 16px;
     max-width: 1100px;
     max-width: 1100px;
     margin: 0 auto;
     margin: 0 auto 50px auto;
     padding: 0 10px;
     padding: 0 12px;
     box-sizing: border-box;
     box-sizing: border-box;
}
}


/* Важливо: стилі саме для вашого шаблону {{Карточка категорії}} */
/* Окрема картка */
.category-card {                         /* ← додайте цей клас у шаблон, якщо його ще немає */
.category-card {
     text-align: center;
     text-align: center;
     background: #f8f9fa;
     background: #ffffff;
    border: 1px solid #e2e8f0;
     border-radius: 10px;
     border-radius: 10px;
     padding: 16px 10px;
     padding: 18px 12px 20px;
     box-shadow: 0 2px 8px rgba(0,0,0,0.08);
     box-shadow: 0 3px 10px rgba(0,0,0,0.06);
     transition: transform 0.12s, box-shadow 0.12s;
     transition: all 0.14s ease;
}
}


.category-card:hover {
.category-card:hover {
     transform: translateY(-4px);
     transform: translateY(-4px);
     box-shadow: 0 6px 16px rgba(0,0,0,0.12);
     box-shadow: 0 8px 20px rgba(0,0,0,0.12);
    border-color: #cbd5e1;
}
}


.category-card img {
/* Блок з картинкою */
     width: 100%;
.card-image {
     max-width: 120px;         /* або підберіть під розмір ваших іконок */
     margin-bottom: 14px;
     height: auto;
}
     margin-bottom: 12px;
 
.card-image img {
     width: 80px;
     height: 80px;
     object-fit: contain;
     display: block;
     display: block;
     margin-left: auto;
     margin: 0 auto;
    margin-right: auto;
}
}


.category-card .title {
/* Назва під картинкою */
     font-size: 16px;
.card-title {
     font-size: 15px;
     font-weight: 600;
     font-weight: 600;
    color: #003d82;
     line-height: 1.35;
     line-height: 1.35;
    color: #1e40af;          /* або #003d82, якщо хочеш той самий колір */
    min-height: 2.8em;      /* щоб рядки вирівнювалися по висоті */
    display: flex;
    align-items: center;
    justify-content: center;
}
.card-title a,
.card-title {
    color: #1e40af;
    text-decoration: none;
}
.card-title a:hover {
    color: #1e3a8a;
    text-decoration: underline;
}
}


/* Адаптивність (мобільні та планшети) */
/* Адаптивність */
@media (max-width: 1024px) {
@media (max-width: 1024px) {
     .category-grid-container {
     .category-grid-container {
         grid-template-columns: repeat(3, 1fr);
         grid-template-columns: repeat(3, 1fr);
        gap: 18px 14px;
     }
     }
}
}


@media (max-width: 720px) {
@media (max-width: 768px) {
     .category-grid-container {
     .category-grid-container {
         grid-template-columns: repeat(2, 1fr);
         grid-template-columns: repeat(2, 1fr);
        gap: 16px 12px;
    }
   
    .card-image img {
        width: 70px;
        height: 70px;
    }
   
    .card-title {
        font-size: 14.5px;
     }
     }
}
}
Рядок 99: Рядок 136:
     .category-grid-container {
     .category-grid-container {
         grid-template-columns: 1fr;
         grid-template-columns: 1fr;
        gap: 16px;
        padding: 0 8px;
    }
   
    .welcome-text,
    .section-projects {
        margin-left: 10px;
        margin-right: 10px;
     }
     }
}
}


/* Загальні стилі */
/* Загальні стилі (якщо ще не були) */
body {
body {
     font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
     font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}
}


a {
a {
     color: #003d82;
     color: #1d4ed8;
}
}


a:hover {
a:hover {
     color: #0052a8;
     color: #1e40af;
}
}

Версія за 10:17, 11 лютого 2026

/* =============================================
   Головна сторінка — привітання та сітка проєктів
   ============================================= */

/* Привітальний блок */
.welcome-text {
    text-align: center;
    font-style: italic;
    margin: 30px auto;
    padding: 30px;
    max-width: 1100px;
    background: #003d82;
    color: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,61,130,0.18);
}

.welcome-text strong {
    color: #ffd700;
    font-size: 24px;
    font-weight: 700;
    display: block;
    margin-top: 12px;
    font-style: normal;
}

/* Заголовок секції "Наші проєкти" */
.section-projects {
    background: #003d82;
    color: #ffd700;
    padding: 16px 24px;
    font-size: 20px;
    font-weight: 700;
    border-radius: 10px;
    margin: 35px auto 25px;
    text-align: center;
    box-shadow: 0 3px 12px rgba(0,61,130,0.15);
    max-width: 1100px;
}

.section-projects .emoji {
    font-size: 28px;
    margin-right: 10px;
    vertical-align: middle;
}

/* Сітка карток — головний контейнер */
.category-grid-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px 16px;
    max-width: 1100px;
    margin: 0 auto 50px auto;
    padding: 0 12px;
    box-sizing: border-box;
}

/* Окрема картка */
.category-card {
    text-align: center;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 18px 12px 20px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.06);
    transition: all 0.14s ease;
}

.category-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.12);
    border-color: #cbd5e1;
}

/* Блок з картинкою */
.card-image {
    margin-bottom: 14px;
}

.card-image img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    display: block;
    margin: 0 auto;
}

/* Назва під картинкою */
.card-title {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.35;
    color: #1e40af;          /* або #003d82, якщо хочеш той самий колір */
    min-height: 2.8em;       /* щоб рядки вирівнювалися по висоті */
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-title a,
.card-title {
    color: #1e40af;
    text-decoration: none;
}

.card-title a:hover {
    color: #1e3a8a;
    text-decoration: underline;
}

/* Адаптивність */
@media (max-width: 1024px) {
    .category-grid-container {
        grid-template-columns: repeat(3, 1fr);
        gap: 18px 14px;
    }
}

@media (max-width: 768px) {
    .category-grid-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px 12px;
    }
    
    .card-image img {
        width: 70px;
        height: 70px;
    }
    
    .card-title {
        font-size: 14.5px;
    }
}

@media (max-width: 480px) {
    .category-grid-container {
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 0 8px;
    }
    
    .welcome-text,
    .section-projects {
        margin-left: 10px;
        margin-right: 10px;
    }
}

/* Загальні стилі (якщо ще не були) */
body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

a {
    color: #1d4ed8;
}

a:hover {
    color: #1e40af;
}