/*
Theme Name: MaTheme
Theme URI: https://matadorbetza.com
Author: Mathem
Author URI: https://matadorbetza.com
Description: Ultra-fast, SEO-optimized WordPress AMP theme with Matadorbet-inspired design. Lightweight, mobile-first, and PageSpeed 100% compliant.
Version: 1.0.0
Requires at least: 5.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: ma-theme
Tags: one-column, two-columns, right-sidebar, custom-menu, featured-images, threaded-comments, translation-ready
*/

/* ========================================
   CSS RESET & BASE
   ======================================== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    line-height: 1.15;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-size: 1rem;
    line-height: 1.7;
    color: #1e293b;
    background-color: #f0f2f5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

a {
    color: #1a2d50;
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover,
a:focus {
    color: #e63946;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul,
ol {
    list-style-position: inside;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    line-height: 1.3;
    color: #0a1628;
    margin-bottom: 0.5em;
}

h1 {
    font-size: 1.75rem;
}

h2 {
    font-size: 1.45rem;
}

h3 {
    font-size: 1.25rem;
}

h4 {
    font-size: 1.1rem;
}

h5 {
    font-size: 1rem;
}

h6 {
    font-size: 0.9rem;
}

p {
    margin-bottom: 1em;
}

table {
    border-collapse: collapse;
    width: 100%;
    margin-bottom: 1.5em;
}

th,
td {
    padding: 0.6em 0.8em;
    border: 1px solid #e2e8f0;
    text-align: left;
}

th {
    background: #1a2d50;
    color: #fff;
    font-weight: 600;
}

blockquote {
    border-left: 4px solid #e63946;
    padding: 0.8em 1.2em;
    margin: 1.2em 0;
    background: #fff;
    color: #475569;
    font-style: italic;
}

pre,
code {
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
    font-size: 0.88rem;
    background: #f1f5f9;
    border-radius: 4px;
}

pre {
    padding: 1em;
    overflow-x: auto;
    margin-bottom: 1.5em;
}

code {
    padding: 0.15em 0.4em;
}

hr {
    border: none;
    border-top: 2px solid #e2e8f0;
    margin: 2em 0;
}

/* ========================================
   LAYOUT
   ======================================== */
.ma-site-wrapper {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 1rem;
}

.ma-content-area {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    padding: 1.5rem 0;
}

.ma-main-content {
    flex: 1;
    min-width: 0;
}

.ma-sidebar {
    width: 300px;
    flex-shrink: 0;
}

/* ========================================
   HEADER
   ======================================== */
.ma-header {
    background: linear-gradient(135deg, #0a1628 0%, #1a2d50 100%);
    color: #fff;
    position: relative;
    border-bottom: 3px solid #e63946;
}

.ma-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.8rem 1rem;
    max-width: 1140px;
    margin: 0 auto;
}

.ma-site-branding {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.ma-site-logo img {
    max-height: 40px;
    width: auto;
}

.ma-site-title {
    font-size: 1.4rem;
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.01em;
}

.ma-site-title a {
    color: #fff;
    text-decoration: none;
}

.ma-site-title a:hover {
    color: #f87171;
}

.ma-site-description {
    font-size: 0.75rem;
    color: #94a3b8;
    margin: 0;
    font-weight: 400;
}

/* ========================================
   NAVIGATION
   ======================================== */
.ma-nav-wrapper {
    background: #1a2d50;
    border-bottom: 1px solid rgba(230, 57, 70, 0.3);
}

.ma-primary-nav {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 1rem;
}

.ma-primary-nav ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    margin: 0;
    padding: 0;
}

.ma-primary-nav ul li {
    position: relative;
}

.ma-primary-nav ul li a {
    display: block;
    color: #e2e8f0;
    padding: 0.65rem 1rem;
    font-size: 0.88rem;
    font-weight: 500;
    transition: background 0.2s ease, color 0.2s ease;
    border-bottom: 2px solid transparent;
}

.ma-primary-nav ul li a:hover,
.ma-primary-nav ul li.current-menu-item>a,
.ma-primary-nav ul li.current_page_item>a {
    background: rgba(230, 57, 70, 0.15);
    color: #fff;
    border-bottom-color: #e63946;
}

/* Sub-menus */
.ma-primary-nav ul li ul.sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #0f1d36;
    min-width: 200px;
    z-index: 100;
    border-top: 2px solid #e63946;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.ma-primary-nav ul li:hover>ul.sub-menu {
    display: block;
}

.ma-primary-nav ul li ul.sub-menu li a {
    padding: 0.55rem 1rem;
    font-size: 0.82rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.ma-primary-nav ul li ul.sub-menu li a:hover {
    background: rgba(230, 57, 70, 0.2);
}

/* Mobile menu toggle */
.ma-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #fff;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.3rem;
    line-height: 1;
}

.ma-menu-toggle-checkbox {
    display: none;
}

/* ========================================
   CONTENT CARDS
   ======================================== */
.ma-post-card {
    background: #fff;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.25rem;
    border: 1px solid #e2e8f0;
    transition: box-shadow 0.2s ease;
}

.ma-post-card:hover {
    box-shadow: 0 2px 12px rgba(10, 22, 40, 0.08);
}

.ma-post-card .entry-title {
    font-size: 1.3rem;
    margin-bottom: 0.4rem;
    line-height: 1.35;
}

.ma-post-card .entry-title a {
    color: #0a1628;
}

.ma-post-card .entry-title a:hover {
    color: #e63946;
}

.ma-post-meta {
    font-size: 0.78rem;
    color: #64748b;
    margin-bottom: 0.7rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.ma-post-meta a {
    color: #64748b;
}

.ma-post-meta a:hover {
    color: #e63946;
}

.ma-post-meta .meta-sep {
    color: #cbd5e1;
}

.ma-post-excerpt {
    color: #475569;
    line-height: 1.65;
    margin-bottom: 0.8rem;
}

.ma-read-more {
    display: inline-block;
    color: #e63946;
    font-weight: 600;
    font-size: 0.85rem;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease;
}

.ma-read-more:hover {
    color: #e63946;
    border-bottom-color: #e63946;
}

.ma-post-thumbnail {
    margin-bottom: 1rem;
    border-radius: 6px;
    overflow: hidden;
}

.ma-post-thumbnail img {
    width: 100%;
    height: auto;
}

/* ========================================
   SINGLE POST / PAGE
   ======================================== */
.ma-single-content {
    background: #fff;
    border-radius: 8px;
    padding: 2rem 1.5rem;
    border: 1px solid #e2e8f0;
}

.ma-single-content .entry-title {
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
    color: #0a1628;
    border-bottom: 3px solid #e63946;
    padding-bottom: 0.5rem;
}

.ma-single-content .entry-content {
    margin-top: 1.2rem;
    line-height: 1.8;
    color: #1e293b;
}

.ma-single-content .entry-content h2 {
    margin-top: 1.8em;
    padding-bottom: 0.3em;
    border-bottom: 2px solid #e2e8f0;
}

.ma-single-content .entry-content h3 {
    margin-top: 1.5em;
}

.ma-single-content .entry-content a {
    color: #e63946;
    border-bottom: 1px solid rgba(230, 57, 70, 0.3);
}

.ma-single-content .entry-content a:hover {
    border-bottom-color: #e63946;
}

.ma-single-content .entry-content ul,
.ma-single-content .entry-content ol {
    margin: 1em 0;
    padding-left: 1.5em;
    list-style-position: outside;
}

.ma-single-content .entry-content li {
    margin-bottom: 0.4em;
}

.ma-single-content .entry-content img {
    border-radius: 6px;
    margin: 1em 0;
}

/* Category & Tag links in posts */
.ma-post-taxonomy {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e2e8f0;
    font-size: 0.85rem;
    color: #64748b;
}

.ma-post-taxonomy a {
    display: inline-block;
    background: #f1f5f9;
    color: #1a2d50;
    padding: 0.2em 0.6em;
    border-radius: 4px;
    font-size: 0.8rem;
    margin: 0.2em 0.15em;
    transition: background 0.2s ease;
}

.ma-post-taxonomy a:hover {
    background: #e63946;
    color: #fff;
}

/* Post Navigation */
.ma-post-navigation {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 1.5rem;
    padding: 1rem 0;
}

.ma-post-navigation .nav-previous,
.ma-post-navigation .nav-next {
    flex: 1;
}

.ma-post-navigation a {
    display: block;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 0.8rem 1rem;
    color: #1a2d50;
    font-size: 0.85rem;
    transition: border-color 0.2s ease;
}

.ma-post-navigation a:hover {
    border-color: #e63946;
    color: #e63946;
}

.ma-post-navigation .nav-label {
    display: block;
    font-size: 0.7rem;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25em;
}

.ma-post-navigation .nav-next {
    text-align: right;
}

/* Related Posts */
.ma-related-posts {
    background: #fff;
    border-radius: 8px;
    padding: 1.5rem;
    margin-top: 1.5rem;
    border: 1px solid #e2e8f0;
}

.ma-related-posts h3 {
    font-size: 1.1rem;
    color: #0a1628;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e63946;
}

.ma-related-posts ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.ma-related-posts ul li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #f1f5f9;
}

.ma-related-posts ul li:last-child {
    border-bottom: none;
}

.ma-related-posts ul li a {
    color: #1a2d50;
    font-weight: 500;
    font-size: 0.9rem;
}

.ma-related-posts ul li a:hover {
    color: #e63946;
}

/* ========================================
   SIDEBAR
   ======================================== */
.ma-sidebar .widget {
    background: #fff;
    border-radius: 8px;
    padding: 1.2rem;
    margin-bottom: 1.25rem;
    border: 1px solid #e2e8f0;
}

.ma-sidebar .widget-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #0a1628;
    margin-bottom: 0.8rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e63946;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.ma-sidebar .widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.ma-sidebar .widget ul li {
    padding: 0.4rem 0;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.88rem;
}

.ma-sidebar .widget ul li:last-child {
    border-bottom: none;
}

.ma-sidebar .widget ul li a {
    color: #1a2d50;
}

.ma-sidebar .widget ul li a:hover {
    color: #e63946;
}

.ma-sidebar .widget p {
    font-size: 0.88rem;
    color: #475569;
}

/* Search widget */
.ma-sidebar .search-form {
    display: flex;
}

.ma-sidebar .search-field {
    flex: 1;
    padding: 0.5rem 0.75rem;
    border: 1px solid #e2e8f0;
    border-right: none;
    border-radius: 6px 0 0 6px;
    font-size: 0.85rem;
    outline: none;
    font-family: inherit;
}

.ma-sidebar .search-field:focus {
    border-color: #e63946;
}

.ma-sidebar .search-submit {
    padding: 0.5rem 1rem;
    background: #e63946;
    color: #fff;
    border: 1px solid #e63946;
    border-radius: 0 6px 6px 0;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    font-family: inherit;
    transition: background 0.2s ease;
}

.ma-sidebar .search-submit:hover {
    background: #dc2626;
}

/* ========================================
   PAGINATION
   ======================================== */
.ma-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.3rem;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.ma-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 0.5rem;
    background: #fff;
    color: #1a2d50;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.ma-pagination .page-numbers:hover {
    border-color: #e63946;
    color: #e63946;
}

.ma-pagination .page-numbers.current {
    background: #e63946;
    color: #fff;
    border-color: #e63946;
}

.ma-pagination .page-numbers.dots {
    border: none;
    background: none;
    color: #94a3b8;
}

/* ========================================
   COMMENTS
   ======================================== */
.ma-comments-area {
    background: #fff;
    border-radius: 8px;
    padding: 1.5rem;
    margin-top: 1.5rem;
    border: 1px solid #e2e8f0;
}

.ma-comments-area .comments-title {
    font-size: 1.15rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e63946;
}

.ma-comments-area .comment-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.ma-comments-area .comment {
    padding: 1rem 0;
    border-bottom: 1px solid #f1f5f9;
}

.ma-comments-area .comment:last-child {
    border-bottom: none;
}

.ma-comments-area .comment-author {
    font-weight: 600;
    color: #0a1628;
    font-size: 0.9rem;
    margin-bottom: 0.2rem;
}

.ma-comments-area .comment-metadata {
    font-size: 0.75rem;
    color: #94a3b8;
    margin-bottom: 0.5rem;
}

.ma-comments-area .comment-metadata a {
    color: #94a3b8;
}

.ma-comments-area .comment-content {
    font-size: 0.9rem;
    line-height: 1.6;
    color: #475569;
}

.ma-comments-area .children {
    list-style: none;
    padding-left: 1.5rem;
    margin: 0;
    border-left: 2px solid #e2e8f0;
}

.ma-comments-area .reply a {
    font-size: 0.78rem;
    color: #e63946;
    font-weight: 600;
}

/* Comment Form */
.ma-comments-area .comment-respond {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e2e8f0;
}

.ma-comments-area .comment-reply-title {
    font-size: 1.05rem;
    margin-bottom: 0.8rem;
}

.ma-comments-area label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.3rem;
}

.ma-comments-area input[type="text"],
.ma-comments-area input[type="email"],
.ma-comments-area input[type="url"],
.ma-comments-area textarea {
    width: 100%;
    padding: 0.55rem 0.75rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.88rem;
    margin-bottom: 0.8rem;
    font-family: inherit;
    outline: none;
    transition: border-color 0.2s ease;
}

.ma-comments-area input:focus,
.ma-comments-area textarea:focus {
    border-color: #e63946;
}

.ma-comments-area .form-submit input[type="submit"] {
    background: #e63946;
    color: #fff;
    border: none;
    padding: 0.6rem 1.5rem;
    border-radius: 6px;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.2s ease;
}

.ma-comments-area .form-submit input[type="submit"]:hover {
    background: #dc2626;
}

/* ========================================
   FOOTER
   ======================================== */
.ma-footer {
    background: linear-gradient(135deg, #0a1628 0%, #0f1d36 100%);
    color: #cbd5e1;
    margin-top: 2rem;
    border-top: 3px solid #e63946;
}

.ma-footer-inner {
    max-width: 1140px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

.ma-footer-widgets {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.ma-footer-widgets .widget {
    flex: 1;
    min-width: 200px;
}

.ma-footer-widgets .widget-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.8rem;
    padding-bottom: 0.4rem;
    border-bottom: 2px solid #e63946;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.ma-footer-widgets .widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.ma-footer-widgets .widget ul li {
    padding: 0.3rem 0;
}

.ma-footer-widgets .widget ul li a,
.ma-footer-widgets .widget a {
    color: #94a3b8;
    font-size: 0.85rem;
    transition: color 0.2s ease;
}

.ma-footer-widgets .widget ul li a:hover,
.ma-footer-widgets .widget a:hover {
    color: #f87171;
}

.ma-footer-widgets .widget p {
    font-size: 0.85rem;
    color: #94a3b8;
    line-height: 1.6;
}

/* Footer legal links */
.ma-footer-legal {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem 1.5rem;
    padding: 1rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 1rem;
}

.ma-footer-legal a {
    color: #94a3b8;
    font-size: 0.8rem;
    font-weight: 500;
    transition: color 0.2s ease;
    letter-spacing: 0.01em;
}

.ma-footer-legal a:hover {
    color: #f87171;
}

/* Footer bottom bar */
.ma-footer-bottom {
    text-align: center;
    font-size: 0.78rem;
    color: #64748b;
}

.ma-footer-bottom a {
    color: #94a3b8;
}

.ma-footer-bottom a:hover {
    color: #f87171;
}

/* ========================================
   ARCHIVE / CATEGORY HEADER
   ======================================== */
.ma-archive-header {
    background: #fff;
    border-radius: 8px;
    padding: 1.2rem 1.5rem;
    margin-bottom: 1.25rem;
    border: 1px solid #e2e8f0;
    border-left: 4px solid #e63946;
}

.ma-archive-header h1 {
    font-size: 1.4rem;
    margin-bottom: 0.3rem;
}

.ma-archive-header .archive-description,
.ma-archive-header .taxonomy-description {
    font-size: 0.88rem;
    color: #64748b;
    margin: 0;
}

/* ========================================
   SEARCH FORM
   ======================================== */
.ma-search-form {
    display: flex;
    max-width: 500px;
    margin: 1rem 0;
}

.ma-search-form .search-field {
    flex: 1;
    padding: 0.6rem 1rem;
    border: 2px solid #e2e8f0;
    border-right: none;
    border-radius: 6px 0 0 6px;
    font-size: 0.9rem;
    outline: none;
    font-family: inherit;
}

.ma-search-form .search-field:focus {
    border-color: #e63946;
}

.ma-search-form .search-submit {
    padding: 0.6rem 1.2rem;
    background: #e63946;
    color: #fff;
    border: 2px solid #e63946;
    border-radius: 0 6px 6px 0;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 600;
    font-family: inherit;
    transition: background 0.2s ease;
}

.ma-search-form .search-submit:hover {
    background: #dc2626;
    border-color: #dc2626;
}

/* ========================================
   404 PAGE
   ======================================== */
.ma-404-content {
    background: #fff;
    border-radius: 8px;
    padding: 3rem 2rem;
    text-align: center;
    border: 1px solid #e2e8f0;
}

.ma-404-content h1 {
    font-size: 3rem;
    color: #e63946;
    margin-bottom: 0.5rem;
}

.ma-404-content p {
    font-size: 1rem;
    color: #64748b;
    margin-bottom: 1.5rem;
}

.ma-404-content .ma-search-form {
    margin: 1.5rem auto;
    justify-content: center;
}

.ma-404-links {
    margin-top: 2rem;
}

.ma-404-links h3 {
    font-size: 1rem;
    margin-bottom: 0.8rem;
}

.ma-404-links ul {
    list-style: none;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
}

.ma-404-links ul li a {
    display: inline-block;
    background: #f1f5f9;
    color: #1a2d50;
    padding: 0.4em 0.8em;
    border-radius: 6px;
    font-size: 0.85rem;
    transition: background 0.2s ease, color 0.2s ease;
}

.ma-404-links ul li a:hover {
    background: #e63946;
    color: #fff;
}

/* ========================================
   BREADCRUMBS
   ======================================== */
.ma-breadcrumbs {
    font-size: 0.78rem;
    color: #94a3b8;
    padding: 0.6rem 0;
    margin-bottom: 0.5rem;
}

.ma-breadcrumbs a {
    color: #64748b;
}

.ma-breadcrumbs a:hover {
    color: #e63946;
}

.ma-breadcrumbs .separator {
    margin: 0 0.3em;
    color: #cbd5e1;
}

/* ========================================
   SCREEN READER TEXT (Accessibility)
   ======================================== */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}

.screen-reader-text:focus {
    background-color: #f1f5f9;
    border-radius: 3px;
    box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.6);
    clip: auto !important;
    clip-path: none;
    color: #0a1628;
    display: block;
    font-size: 0.88rem;
    font-weight: 600;
    height: auto;
    left: 5px;
    line-height: normal;
    padding: 0.8rem 1.2rem;
    text-decoration: none;
    top: 5px;
    width: auto;
    z-index: 100000;
}

/* ========================================
   MOBILE SUB-MENU TOGGLE (Walker ile çalışır)
   ======================================== */
.ma-sub-checkbox {
    display: none;
}

.ma-menu-item-wrap {
    display: flex;
    align-items: stretch;
}

.ma-menu-item-wrap>a {
    flex: 1;
}

.ma-sub-arrow {
    display: none;
}

/* ========================================
   RESPONSIVE — MOBILE FIRST
   ======================================== */
@media (max-width: 768px) {
    .ma-content-area {
        flex-direction: column;
    }

    .ma-sidebar {
        width: 100%;
    }

    .ma-header-inner {
        padding: 0.6rem 0.8rem;
    }

    .ma-site-title {
        font-size: 1.15rem;
    }

    /* Mobile menu */
    .ma-menu-toggle {
        display: block;
    }

    .ma-primary-nav ul {
        display: none;
        flex-direction: column;
    }

    .ma-menu-toggle-checkbox:checked~.ma-nav-wrapper .ma-primary-nav ul {
        display: flex;
    }

    .ma-primary-nav ul li a {
        padding: 0.75rem 1rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    }

    /* Sub-menu arrow toggle — visible only on mobile */
    .ma-sub-arrow {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 48px;
        min-width: 48px;
        color: #94a3b8;
        font-size: 1.1rem;
        cursor: pointer;
        border-left: 1px solid rgba(255, 255, 255, 0.08);
        transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
        user-select: none;
        -webkit-tap-highlight-color: transparent;
    }

    .ma-sub-arrow:hover,
    .ma-sub-arrow:active {
        background: rgba(230, 57, 70, 0.15);
        color: #f87171;
    }

    /* Arrow rotates when sub-menu is open */
    .ma-sub-checkbox:checked+.ma-sub-arrow {
        transform: rotate(180deg);
        color: #e63946;
        background: rgba(230, 57, 70, 0.1);
    }

    /* Sub-menu: hidden by default on mobile */
    .ma-primary-nav ul li ul.sub-menu {
        position: static;
        display: none;
        box-shadow: none;
        border-top: none;
        background: rgba(0, 0, 0, 0.15);
    }

    /* Sub-menu: shown when checkbox is checked */
    .ma-sub-checkbox:checked~ul.sub-menu {
        display: block;
    }

    .ma-primary-nav ul li ul.sub-menu li a {
        padding: 0.65rem 1rem 0.65rem 2rem;
        font-size: 0.83rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    }

    .ma-primary-nav ul li ul.sub-menu li a:hover {
        background: rgba(230, 57, 70, 0.12);
    }

    .ma-single-content {
        padding: 1.2rem 1rem;
    }

    h1 {
        font-size: 1.4rem;
    }

    h2 {
        font-size: 1.2rem;
    }

    .ma-post-navigation {
        flex-direction: column;
    }

    .ma-post-navigation .nav-next {
        text-align: left;
    }

    .ma-footer-widgets {
        flex-direction: column;
    }

    .ma-footer-legal {
        flex-direction: column;
        align-items: center;
        gap: 0.5rem;
    }

    .ma-404-content {
        padding: 2rem 1rem;
    }

    .ma-404-content h1 {
        font-size: 2.2rem;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 0.93rem;
    }

    .ma-post-card {
        padding: 1rem;
    }

    .ma-site-description {
        display: none;
    }
}

/* ========================================
   ALIGNMENT CLASSES (WordPress)
   ======================================== */
.alignleft {
    float: left;
    margin-right: 1.5em;
    margin-bottom: 1em;
}

.alignright {
    float: right;
    margin-left: 1.5em;
    margin-bottom: 1em;
}

.aligncenter {
    clear: both;
    display: block;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 1em;
}

.wp-caption {
    max-width: 100%;
    margin-bottom: 1em;
}

.wp-caption-text {
    font-size: 0.8rem;
    color: #94a3b8;
    text-align: center;
    padding: 0.3em 0.5em;
}

/* Gallery */
.gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5em;
}

.gallery-item {
    flex: 1 1 calc(33.333% - 0.5rem);
    max-width: calc(33.333% - 0.5rem);
}

.gallery-item img {
    border-radius: 4px;
}

/* ========================================
   NO RESULTS / EMPTY STATES
   ======================================== */
.ma-no-results {
    background: #fff;
    border-radius: 8px;
    padding: 2rem 1.5rem;
    text-align: center;
    border: 1px solid #e2e8f0;
}

.ma-no-results h1 {
    font-size: 1.3rem;
    color: #1a2d50;
    margin-bottom: 0.5rem;
}

.ma-no-results p {
    color: #64748b;
    margin-bottom: 1rem;
}

/* ========================================
   PRINT STYLES
   ======================================== */
@media print {

    .ma-header,
    .ma-footer,
    .ma-sidebar,
    .ma-nav-wrapper,
    .ma-post-navigation,
    .ma-related-posts,
    .ma-comments-area {
        display: none !important;
    }

    body {
        background: #fff;
        color: #000;
        font-size: 12pt;
    }

    .ma-single-content {
        border: none;
        padding: 0;
        box-shadow: none;
    }

    a {
        color: #000;
        text-decoration: underline;
    }
}