/* ===================================
   ОБЩИЕ СТИЛИ
==================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #ff4757;
    --secondary-color: #2f3542;
    --text-dark: #2c2c2c;
    --text-light: #666;
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
    --border-color: #e1e8ed;
    --shadow: 0 2px 10px rgba(0,0,0,0.08);
    --shadow-hover: 0 5px 20px rgba(0,0,0,0.12);
}

body {
    font-family: 'Open Sans', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    background-color: var(--bg-light);
}

.decdfcontainer {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ===================================
   HERO SECTION
   =================================== */

.decdfhero {
    position: relative;
    height: 250px;
    background-image: url('../images/decdf/logo.png');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}

.decdfhero-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(255, 255, 255, 0.85);
}

.decdfhero-content {
    position: relative;
    z-index: 2;
}

.decdfhero-title {
    font-family: 'Playfair Display', serif;
    font-size: 4rem;
    font-weight: 900;
    letter-spacing: 2px;
    margin-bottom: 10px;
    color: var(--text-dark);
    text-transform: uppercase;
}

.decdfhero-subtitle {
    font-size: 1.1rem;
    letter-spacing: 3px;
    color: var(--text-light);
    font-weight: 400;
    text-transform: uppercase;
}

/* ===================================
   NAVIGATION
   =================================== */

.decdfnavbar {
    background: var(--bg-white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.decdfnavbar .decdfcontainer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.decdfnav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
    align-items: center;
    flex: 1;
}

.decdfnav-link {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-dark);
    padding: 10px 0;
    position: relative;
    display: flex;
    align-items: center;
    gap: 5px;
}

.decdfnav-link:hover,
.decdfnav-link.active {
    color: var(--primary-color);
}

.decdfnav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 2px;
    background: var(--primary-color);
}

.decdfdropdown {
    position: relative;
}

.decdfdropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--bg-white);
    list-style: none;
    min-width: 200px;
    box-shadow: var(--shadow-hover);
    border-radius: 4px;
    padding: 10px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.decdfdropdown:hover .decdfdropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.decdfdropdown-menu li a {
    display: block;
    padding: 10px 20px;
    color: var(--text-dark);
    font-size: 0.9rem;
}

.decdfdropdown-menu li a:hover {
    background: var(--bg-light);
    color: var(--primary-color);
}

.decdfmobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-dark);
}

/* ===================================
   MAIN CONTENT
   =================================== */

.decdfmain-content {
    padding: 60px 0;
}

.decdfcontent-wrapper {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 40px;
}

/* ===================================
   BLOG POSTS
   =================================== */

.decdfblog-posts {
    display: flex;
    flex-direction: column;
    gap: 50px;
}

.decdfblog-post {
    background: var(--bg-white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    display: grid;
    grid-template-columns: 400px 1fr;
    transition: all 0.3s ease;
    animation: fadeIn 0.6s ease forwards;
}

.decdfblog-post:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-5px);
}

.decdfpost-image {
    overflow: hidden;
}

.decdfpost-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.decdfblog-post:hover .decdfpost-image img {
    transform: scale(1.05);
}

.decdfpost-content {
    padding: 30px 30px 30px 25px;
    display: flex;
    flex-direction: column;
}

.decdfpost-tag {
    display: inline-block;
    background: var(--primary-color);
    color: white;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 15px;
    align-self: flex-start;
}

.decdfpost-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 15px;
    line-height: 1.3;
    color: var(--text-dark);
}

.decdfpost-title:hover {
    color: var(--primary-color);
}

.decdfpost-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
    font-size: 0.9rem;
    color: var(--text-light);
}

.decdfpost-meta i {
    margin-right: 5px;
    color: var(--primary-color);
}

.decdfpost-excerpt {
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 20px;
}

.decdfread-more {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: auto;
}

.decdfread-more:hover {
    gap: 12px;
}

/* ===================================
   PAGINATION
   =================================== */

.decdfpagination {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 30px;
    flex-wrap: wrap;
}

.decdfpage-link {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-white);
    border-radius: 4px;
    font-weight: 600;
    color: var(--text-dark);
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.decdfpage-link:hover:not(.active):not(.disabled) {
    background: var(--primary-color);
    color: white;
}

.decdfpage-link.active {
    background: var(--primary-color);
    color: white;
}

.decdfpage-link.disabled {
    color: #ccc;
    cursor: not-allowed;
    opacity: 0.6;
}

/* ===================================
   SIDEBAR
   =================================== */

.decdfsidebar {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.decdfwidget {
    background: var(--bg-white);
    border-radius: 8px;
    padding: 30px;
    box-shadow: var(--shadow);
}

.decdfwidget-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 3px solid var(--primary-color);
}

/* Categories */
.decdfcategories-list {
    list-style: none;
}

.decdfcategories-list li {
    border-bottom: 1px solid var(--border-color);
}

.decdfcategories-list li:last-child {
    border-bottom: none;
}

.decdfcategories-list a {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    color: var(--text-dark);
    font-weight: 500;
}

.decdfcategories-list a:hover {
    color: var(--primary-color);
    padding-left: 10px;
}

.decdfcategories-list li.active a {
    color: var(--primary-color);
    font-weight: 700;
}

.decdfcategories-list span {
    color: var(--text-light);
    font-size: 0.9rem;
}

/* Recommend Widget */
.decdflatest-articles {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.decdfmini-post {
    display: flex;
    gap: 15px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.decdfmini-post:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.decdfmini-post-image {
    width: 80px;
    height: 80px;
    flex-shrink: 0;
    border-radius: 4px;
    overflow: hidden;
}

.decdfmini-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.decdfmini-post-title {
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.4;
    color: var(--text-dark);
}

.decdfmini-post-title a:hover {
    color: var(--primary-color);
}

/* ===================================
   FOOTER
   =================================== */

.decdffooter {
    background: var(--secondary-color);
    color: white;
    padding: 30px 0;
    margin-top: 60px;
    text-align: center;
}

.decdffooter .decdfcontainer {
    display: flex;
    justify-content: center;
    align-items: center;
}

/* ===================================
   АНИМАЦИИ
   =================================== */

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===================================
   АДАПТИВНОСТЬ
   =================================== */

@media (max-width: 1024px) {
    .decdfhero-title { font-size: 3rem; }
    .decdfcontent-wrapper { grid-template-columns: 1fr 300px; gap: 30px; }
    .decdfblog-post { grid-template-columns: 300px 1fr; }
    .decdfnav-menu { gap: 20px; }
}

@media (max-width: 768px) {
    .decdfhero { height: 100px; }
    .decdfmain-content { padding: 30px 0; }
    .decdfhero-title { font-size: 2rem; letter-spacing: 1px; }
    .decdfhero-subtitle { font-size: 0.9rem; letter-spacing: 1px; }
    .decdfnavbar .decdfcontainer { flex-wrap: wrap; padding: 10px 20px; }
    .decdfmobile-menu-toggle { display: block; }
    .decdfnav-menu {
        display: flex;
        flex-direction: column;
        width: 100%;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
        gap: 0;
        background: var(--bg-white);
    }
    .decdfnav-menu.decdfactive { max-height: 600px; padding: 10px 0; }
    .decdfnav-item { width: 100%; text-align: center; border-bottom: 1px solid var(--border-color); }
    .decdfnav-item.decdfdropdown { border-bottom: none; }
    .decdfdropdown-menu li { border-top: 1px solid rgba(0,0,0,0.06); text-align: center; }
    .decdfnav-link { padding: 15px; justify-content: center; }
    .decdfdropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }
    .decdfdropdown:hover .decdfdropdown-menu { max-height: 300px; }
    .decdfcontent-wrapper { grid-template-columns: 1fr; }
    .decdfblog-post { grid-template-columns: 1fr; }
    .decdfpost-image { height: 250px; }
    .decdfpost-content { padding: 20px; }
    .decdfpost-title { font-size: 1.5rem; }
    .decdfpost-meta { flex-direction: column; gap: 5px; }
    .decdfsidebar { order: -1; }
    .decdffooter .decdfcontainer { flex-direction: column; gap: 10px; }
}

@media (max-width: 480px) {
    .decdfcontainer { padding: 0 15px; }
    .decdfhero-title { font-size: 1.5rem; }
    .decdfhero-subtitle { font-size: 0.75rem; }
    .decdfpost-title { font-size: 1.3rem; }
    .decdfwidget { padding: 20px; }
    .decdfpagination { gap: 6px; }
    .decdfpage-link { width: 35px; height: 35px; font-size: 0.85rem; }
}

/* ===================================
   ФОРМА ОБРАТНОЙ СВЯЗИ (about.php)
=================================== */
.decdfcf-block{background:var(--bg-white);border:1px solid var(--border-color);border-radius:12px;padding:32px;margin-top:40px;box-shadow:var(--shadow)}
.decdfcf-block h2{margin:0 0 6px;font-size:20px;color:var(--text-dark);font-family:'Playfair Display',serif}
.decdfcf-sub{color:var(--text-light);font-size:14px;margin:0 0 24px}
.decdfcf-row{margin-bottom:16px}
.decdfcf-row label{display:block;margin-bottom:5px;font-weight:600;font-size:13px;color:var(--text-dark)}
.decdfcf-row input,.decdfcf-row textarea{width:100%;padding:10px 14px;border:1px solid var(--border-color);border-radius:8px;font-size:14px;font-family:inherit;box-sizing:border-box;transition:border-color .2s;background:#fff}
.decdfcf-row input:focus,.decdfcf-row textarea:focus{outline:none;border-color:var(--primary-color)}
.decdfcf-row textarea{min-height:120px;resize:vertical}
.decdfcf-captcha-row{display:flex;align-items:center;gap:12px}
.decdfcf-captcha-q{background:var(--bg-light);border:1px solid var(--border-color);border-radius:8px;padding:10px 16px;font-weight:700;font-size:15px;color:var(--text-dark);white-space:nowrap}
.decdfcf-captcha-row input{max-width:100px}
.decdfcf-btn{display:inline-flex;align-items:center;gap:8px;background:var(--primary-color);color:#fff;border:none;padding:12px 28px;border-radius:8px;font-size:14px;font-weight:600;cursor:pointer;transition:background .2s;font-family:inherit}
.decdfcf-btn:hover{background:#e03040}
.decdfcf-ok{background:#dcfce7;border:1px solid #86efac;border-radius:8px;padding:14px 18px;color:#166534;margin-bottom:18px;font-size:14px}
.decdfcf-err{background:#fee2e2;border:1px solid #fca5a5;border-radius:8px;padding:14px 18px;color:#991b1b;margin-bottom:18px;font-size:14px}

