/*
Theme Name: My Press Theme
Theme URI: https://example.com
Author: Aniket
Description: Simple WordPress Press/News Theme
Version: 1.0
*/

* {
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-width: 320px;
    overflow-x: hidden;
    font-family: Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    background: #f5f5f5;
    color: #222;
}

img,
video,
iframe {
    max-width: 100%;
    height: auto;
}

.container {
    width: min(94%, 1100px);
    margin: 0 auto;
}

.site-header {
    background: #0b7a3b;
    color: white;
    padding: 22px 0;
}

.site-title {
    margin: 0;
    font-size: clamp(24px, 4vw, 34px);
    line-height: 1.2;
    overflow-wrap: anywhere;
}

.site-description {
    margin: 8px 0 0;
    font-size: clamp(13px, 2vw, 16px);
    line-height: 1.5;
}

.hero {
    background: white;
    margin: clamp(16px, 3vw, 30px) auto;
    padding: clamp(28px, 5vw, 55px) clamp(18px, 5vw, 40px);
    border-radius: 12px;
    text-align: center;
    overflow-wrap: anywhere;
}

.hero h1 {
    margin: 0 0 12px;
    color: #0b7a3b;
    font-size: clamp(26px, 5vw, 42px);
    line-height: 1.2;
}

.hero p {
    margin: 0 auto;
    max-width: 760px;
}

.news-area {
    background: white;
    padding: clamp(18px, 3vw, 30px);
    border-radius: 12px;
    overflow: hidden;
}

.news-title {
    margin: 0 0 12px;
    border-left: 5px solid #0b7a3b;
    padding-left: 12px;
    font-size: clamp(22px, 3vw, 30px);
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.post {
    padding: clamp(16px, 2.5vw, 24px) 0;
    border-bottom: 1px solid #ddd;
    overflow-wrap: anywhere;
}

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

.post h2 {
    margin: 0 0 8px;
    font-size: clamp(20px, 3vw, 28px);
    line-height: 1.3;
}

.post h2 a {
    color: #111;
    text-decoration: none;
}

.post h2 a:hover,
.post h2 a:focus {
    color: #0b7a3b;
}

.post p {
    margin: 0;
}

.site-footer {
    margin-top: clamp(24px, 5vw, 40px);
    padding: 24px 15px;
    background: #111;
    color: white;
    text-align: center;
    overflow-wrap: anywhere;
}

@media (min-width: 601px) and (max-width: 900px) {
    .site-header {
        padding: 24px 0;
    }

    .container {
        width: 90%;
    }

    .hero {
        padding: 40px 28px;
    }

    .news-area {
        padding: 24px;
    }
}

@media (min-width: 901px) {
    .site-header {
        padding: 26px 0;
    }

    .hero,
    .news-area {
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    }
}

@media (max-width: 600px) {
    body {
        font-size: 15px;
    }

    .site-header {
        padding: 18px 0;
    }

    .container {
        width: calc(100% - 30px);
    }

    .hero {
        padding: 25px 15px;
        border-radius: 8px;
    }

    .news-area {
        padding: 15px;
        border-radius: 8px;
    }

    .news-title {
        padding-left: 9px;
    }

    .post {
        padding: 15px 0;
    }

    .site-footer {
        padding: 20px 15px;
    }
}

@media (max-width: 380px) {
    .container {
        width: calc(100% - 24px);
    }

    .hero,
    .news-area {
        padding-left: 12px;
        padding-right: 12px;
    }
}





/* HEADER */

.site-header {
    background: #0b7a3b;
    color: white;
}

.header-inner {
    width: min(94%, 1100px);
    min-height: 65px;
    margin: auto;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;

    position: relative;
}

.header-logo {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}

.header-logo a {
    color: white;
    text-decoration: none;
    font-size: 25px;
    font-weight: bold;
    white-space: nowrap;
}

.menu-btn,
.search-btn {
    border: 0;
    background: transparent;
    color: white;
    cursor: pointer;
    font-size: 17px;
    padding: 10px;
}

.header-menu {
    position: relative;
}

.main-menu {
    display: none;
    position: absolute;
    top: 48px;
    left: 0;
    min-width: 190px;
    background: white;
    border-radius: 8px;
    padding: 10px;
    z-index: 9999;
    box-shadow: 0 5px 20px rgba(0,0,0,.2);
}

.main-menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.main-menu li {
    margin: 0;
    padding: 0;
}

.main-menu a {
    display: block;
    color: #222;
    text-decoration: none;
    padding: 10px 12px;
}

.main-menu a:hover {
    background: #e8f5e9;
    color: #0b7a3b;
}

.header-search {
    margin-left: auto;
    position: relative;
}

.search-box {
    display: none;
    position: absolute;
    right: 0;
    top: 48px;
    background: white;
    padding: 10px;
    border-radius: 8px;
    z-index: 9999;
    box-shadow: 0 5px 20px rgba(0,0,0,.2);
}

.search-box form {
    display: flex;
    gap: 5px;
}

.search-box input {
    width: 180px;
    padding: 9px;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.search-box button {
    background: #0b7a3b;
    color: white;
    border: 0;
    padding: 9px 12px;
    border-radius: 5px;
}

@media (max-width: 600px) {

    .header-inner {
        min-height: 58px;
    }

    .header-logo a {
        font-size: 19px;
    }

    .menu-btn {
        font-size: 14px;
    }

    .search-box input {
        width: 150px;
    }
}