@charset "UTF-8";
/*
Theme Name: Nila
Description: Main stylesheet for core theme styles
Version: 1.0.0
Author: Amir Sheikhzadeh
Designer: Morteza Haghani
*/

/**
 * Table of Contents
 *
 * 1.0 - CSS Variables
 * 2.0 - Base Styles
 * 3.0 - Typography
 * 4.0 - Layout
 * 5.0 - Header
 * 6.0 - Navigation
 * 7.0 - Content
 * 8.0 - Sidebar
 * 9.0 - Footer
 * 10.0 - Posts/Blog
 * 11.0 - Comments
 * 12.0 - Widgets
 * 13.0 - Forms
 * 14.0 - Buttons
 * 15.0 - Pagination
 * 16.0 - 404 & Search
 * 17.0 - Utilities
 * 18.0 - Responsive
 */

/* ==========================================================================
   1.0 - CSS Variables
   ========================================================================== */

:root {
    /* Colors */
    --nila-primary: #0073aa;
    --nila-secondary: #005177;
    --nila-text: #333333;
    --nila-text-light: #666666;
    --nila-border: #e5e5e5;
    --nila-bg: #ffffff;
    --nila-bg-light: #f9f9f9;
    --nila-bg-dark: #1a1a1a;
    
    /* Typography */
    --nila-font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --nila-font-heading: inherit;
    --nila-font-size-base: 16px;
    --nila-line-height-base: 1.6;
    
    /* Spacing */
    --nila-spacing-xs: 0.5rem;
    --nila-spacing-sm: 1rem;
    --nila-spacing-md: 1.5rem;
    --nila-spacing-lg: 2rem;
    --nila-spacing-xl: 3rem;
    
    /* Container */
    --nila-container-width: 1200px;
    --nila-container-padding: 20px;
    
    /* Border Radius */
    --nila-radius-sm: 4px;
    --nila-radius-md: 8px;
    --nila-radius-lg: 12px;
    
    /* Shadows */
    --nila-shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --nila-shadow-md: 0 4px 8px rgba(0, 0, 0, 0.1);
    --nila-shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.15);
    
    /* Transitions */
    --nila-transition: all 0.3s ease;
}

/* ==========================================================================
   2.0 - Base Styles
   ========================================================================== */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    font-size: var(--nila-font-size-base);
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    font-family: var(--nila-font-body);
    font-size: 1rem;
    line-height: var(--nila-line-height-base);
    color: var(--nila-text);
    background-color: var(--nila-bg);
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

a {
    color: var(--nila-primary);
    text-decoration: none;
    transition: var(--nila-transition);
}

a:hover,
a:focus {
    color: var(--nila-secondary);
    outline: none;
}

/* ==========================================================================
   3.0 - Typography
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
    font-family: var(--nila-font-heading);
    font-weight: 600;
    line-height: 1.3;
    margin-top: 0;
    margin-bottom: var(--nila-spacing-sm);
    color: var(--nila-text);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
    margin-top: 0;
    margin-bottom: var(--nila-spacing-md);
}

ul, ol {
    margin: 0 0 var(--nila-spacing-md);
    padding-left: 2rem;
}

blockquote {
    margin: var(--nila-spacing-lg) 0;
    padding: var(--nila-spacing-md) var(--nila-spacing-lg);
    border-left: 4px solid var(--nila-primary);
    background: var(--nila-bg-light);
    font-style: italic;
}

code {
    padding: 2px 6px;
    background: var(--nila-bg-light);
    border-radius: var(--nila-radius-sm);
    font-size: 0.9em;
    font-family: "Courier New", monospace;
}

pre {
    padding: var(--nila-spacing-md);
    background: var(--nila-bg-light);
    border-radius: var(--nila-radius-md);
    overflow-x: auto;
    margin: var(--nila-spacing-md) 0;
}

pre code {
    padding: 0;
    background: none;
}

/* ==========================================================================
   4.0 - Layout
   ========================================================================== */

.site {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.site-content {
    flex: 1;
    padding: var(--nila-spacing-xl) 0;
}

.container {
    max-width: var(--nila-container-width);
    margin: 0 auto;
    padding: 0 var(--nila-container-padding);
}

.row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -15px;
}

/* Base Column Classes - Always 100% width on mobile */
[class*="col-"] {
    position: relative;
    width: 100%;
    padding: 0 15px;
}

.col-1 { flex: 0 0 8.333333%; max-width: 8.333333%; }
.col-2 { flex: 0 0 16.666667%; max-width: 16.666667%; }
.col-3 { flex: 0 0 25%; max-width: 25%; }
.col-4 { flex: 0 0 33.333333%; max-width: 33.333333%; }
.col-5 { flex: 0 0 41.666667%; max-width: 41.666667%; }
.col-6 { flex: 0 0 50%; max-width: 50%; }
.col-7 { flex: 0 0 58.333333%; max-width: 58.333333%; }
.col-8 { flex: 0 0 66.666667%; max-width: 66.666667%; }
.col-9 { flex: 0 0 75%; max-width: 75%; }
.col-10 { flex: 0 0 83.333333%; max-width: 83.333333%; }
.col-11 { flex: 0 0 91.666667%; max-width: 91.666667%; }
.col-12 { flex: 0 0 100%; max-width: 100%; }

/* Small devices (landscape phones, 576px and up) */
@media (min-width: 576px) {
    .col-sm-1 { flex: 0 0 8.333333%; max-width: 8.333333%; }
    .col-sm-2 { flex: 0 0 16.666667%; max-width: 16.666667%; }
    .col-sm-3 { flex: 0 0 25%; max-width: 25%; }
    .col-sm-4 { flex: 0 0 33.333333%; max-width: 33.333333%; }
    .col-sm-5 { flex: 0 0 41.666667%; max-width: 41.666667%; }
    .col-sm-6 { flex: 0 0 50%; max-width: 50%; }
    .col-sm-7 { flex: 0 0 58.333333%; max-width: 58.333333%; }
    .col-sm-8 { flex: 0 0 66.666667%; max-width: 66.666667%; }
    .col-sm-9 { flex: 0 0 75%; max-width: 75%; }
    .col-sm-10 { flex: 0 0 83.333333%; max-width: 83.333333%; }
    .col-sm-11 { flex: 0 0 91.666667%; max-width: 91.666667%; }
    .col-sm-12 { flex: 0 0 100%; max-width: 100%; }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) {
    .col-md-1 { flex: 0 0 8.333333%; max-width: 8.333333%; }
    .col-md-2 { flex: 0 0 16.666667%; max-width: 16.666667%; }
    .col-md-3 { flex: 0 0 25%; max-width: 25%; }
    .col-md-4 { flex: 0 0 33.333333%; max-width: 33.333333%; }
    .col-md-5 { flex: 0 0 41.666667%; max-width: 41.666667%; }
    .col-md-6 { flex: 0 0 50%; max-width: 50%; }
    .col-md-7 { flex: 0 0 58.333333%; max-width: 58.333333%; }
    .col-md-8 { flex: 0 0 66.666667%; max-width: 66.666667%; }
    .col-md-9 { flex: 0 0 75%; max-width: 75%; }
    .col-md-10 { flex: 0 0 83.333333%; max-width: 83.333333%; }
    .col-md-11 { flex: 0 0 91.666667%; max-width: 91.666667%; }
    .col-md-12 { flex: 0 0 100%; max-width: 100%; }
}

/* Large devices (desktops, 992px and up) */
@media (min-width: 992px) {
    .col-lg-1 { flex: 0 0 8.333333%; max-width: 8.333333%; }
    .col-lg-2 { flex: 0 0 16.666667%; max-width: 16.666667%; }
    .col-lg-3 { flex: 0 0 25%; max-width: 25%; }
    .col-lg-4 { flex: 0 0 33.333333%; max-width: 33.333333%; }
    .col-lg-5 { flex: 0 0 41.666667%; max-width: 41.666667%; }
    .col-lg-6 { flex: 0 0 50%; max-width: 50%; }
    .col-lg-7 { flex: 0 0 58.333333%; max-width: 58.333333%; }
    .col-lg-8 { flex: 0 0 66.666667%; max-width: 66.666667%; }
    .col-lg-9 { flex: 0 0 75%; max-width: 75%; }
    .col-lg-10 { flex: 0 0 83.333333%; max-width: 83.333333%; }
    .col-lg-11 { flex: 0 0 91.666667%; max-width: 91.666667%; }
    .col-lg-12 { flex: 0 0 100%; max-width: 100%; }
}

/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    .col-xl-1 { flex: 0 0 8.333333%; max-width: 8.333333%; }
    .col-xl-2 { flex: 0 0 16.666667%; max-width: 16.666667%; }
    .col-xl-3 { flex: 0 0 25%; max-width: 25%; }
    .col-xl-4 { flex: 0 0 33.333333%; max-width: 33.333333%; }
    .col-xl-5 { flex: 0 0 41.666667%; max-width: 41.666667%; }
    .col-xl-6 { flex: 0 0 50%; max-width: 50%; }
    .col-xl-7 { flex: 0 0 58.333333%; max-width: 58.333333%; }
    .col-xl-8 { flex: 0 0 66.666667%; max-width: 66.666667%; }
    .col-xl-9 { flex: 0 0 75%; max-width: 75%; }
    .col-xl-10 { flex: 0 0 83.333333%; max-width: 83.333333%; }
    .col-xl-11 { flex: 0 0 91.666667%; max-width: 91.666667%; }
    .col-xl-12 { flex: 0 0 100%; max-width: 100%; }
}

/* Layout Variations */
.layout-right-sidebar .content-area {
    order: 1;
}

.layout-right-sidebar .sidebar {
    order: 2;
}

.layout-left-sidebar .content-area {
    order: 2;
}

.layout-left-sidebar .sidebar {
    order: 1;
}

.boxed-layout .site {
    max-width: var(--nila-container-width);
    margin: 0 auto;
    box-shadow: var(--nila-shadow-lg);
}

/* ==========================================================================
   5.0 - Header
   ========================================================================== */

.site-header {
    background: var(--nila-bg);
    border-bottom: 1px solid var(--nila-border);
    position: relative;
    z-index: 999;
}

.sticky-header-enabled .site-header {
    position: sticky;
    top: 0;
}

.top-bar {
    background: var(--nila-bg-light);
    padding: var(--nila-spacing-xs) 0;
    border-bottom: 1px solid var(--nila-border);
    font-size: 0.875rem;
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-bar-left span,
.top-bar-right span {
    margin-right: var(--nila-spacing-sm);
}

.top-bar a {
    color: var(--nila-text);
}

.main-header {
    padding: var(--nila-spacing-md) 0;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-branding {
    display: flex;
    align-items: center;
}

.custom-logo-link {
    display: block;
}

.custom-logo {
    max-height: 60px;
    width: auto;
}

.site-title {
    margin: 0;
    font-size: 1.75rem;
    font-weight: 700;
}

.site-title a {
    color: var(--nila-text);
}

.site-description {
    margin: 0;
    font-size: 0.875rem;
    color: var(--nila-text-light);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: var(--nila-spacing-sm);
}

.header-actions button,
.header-actions a {
    background: none;
    border: none;
    padding: var(--nila-spacing-xs);
    cursor: pointer;
    font-size: 1.25rem;
    color: var(--nila-text);
    transition: var(--nila-transition);
    position: relative;
}

.header-actions button:hover,
.header-actions a:hover {
    color: var(--nila-primary);
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--nila-primary);
    color: white;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
}

/* ==========================================================================
   6.0 - Navigation
   ========================================================================== */

.main-navigation {
    display: flex;
    align-items: center;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    padding: var(--nila-spacing-xs);
    cursor: pointer;
    font-size: 1.5rem;
}

.nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-menu li {
    position: relative;
}

.nav-menu a {
    display: block;
    padding: var(--nila-spacing-xs) var(--nila-spacing-md);
    color: var(--nila-text);
    font-weight: 500;
}

.nav-menu a:hover,
.nav-menu .current-menu-item > a {
    color: var(--nila-primary);
}

/* Submenu */
.nav-menu .sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--nila-bg);
    box-shadow: var(--nila-shadow-md);
    min-width: 220px;
    list-style: none;
    margin: 0;
    padding: var(--nila-spacing-xs) 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: var(--nila-transition);
    z-index: 1000;
}

.nav-menu li:hover > .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-menu .sub-menu li {
    display: block;
}

.nav-menu .sub-menu a {
    padding: var(--nila-spacing-xs) var(--nila-spacing-md);
}

/* Mobile Menu */
.mobile-menu-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    display: none;
}

.mobile-menu-wrapper.active {
    display: block;
}

.mobile-menu-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
}

.mobile-menu-content {
    position: absolute;
    top: 0;
    right: 0;
    width: 300px;
    height: 100%;
    background: var(--nila-bg);
    padding: var(--nila-spacing-lg);
    overflow-y: auto;
    transform: translateX(100%);
    transition: var(--nila-transition);
}

.mobile-menu-wrapper.active .mobile-menu-content {
    transform: translateX(0);
}

.mobile-menu-close {
    position: absolute;
    top: var(--nila-spacing-sm);
    right: var(--nila-spacing-sm);
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
}

.mobile-nav-menu {
    list-style: none;
    margin: var(--nila-spacing-xl) 0 0;
    padding: 0;
}

.mobile-nav-menu li {
    border-bottom: 1px solid var(--nila-border);
}

.mobile-nav-menu a {
    display: block;
    padding: var(--nila-spacing-sm);
    color: var(--nila-text);
}

/* ==========================================================================
   7.0 - Content
   ========================================================================== */

.entry-header {
    margin-bottom: var(--nila-spacing-lg);
}

.entry-title {
    margin-bottom: var(--nila-spacing-sm);
}

.entry-title a {
    color: var(--nila-text);
}

.entry-title a:hover {
    color: var(--nila-primary);
}

.entry-meta {
    display: flex;
    flex-wrap: wrap;
    gap: var(--nila-spacing-md);
    font-size: 0.875rem;
    color: var(--nila-text-light);
    margin-bottom: var(--nila-spacing-md);
}

.entry-meta span {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.entry-meta a {
    color: var(--nila-text-light);
}

.entry-meta a:hover {
    color: var(--nila-primary);
}

.entry-content {
    margin-bottom: var(--nila-spacing-lg);
}

.entry-content p:last-child {
    margin-bottom: 0;
}

.entry-footer {
    padding-top: var(--nila-spacing-md);
    border-top: 1px solid var(--nila-border);
}

.page-links {
    margin-top: var(--nila-spacing-lg);
    display: flex;
    gap: var(--nila-spacing-xs);
}

.page-links a,
.page-links span {
    padding: var(--nila-spacing-xs) var(--nila-spacing-sm);
    background: var(--nila-bg-light);
    border-radius: var(--nila-radius-sm);
}

/* ==========================================================================
   10.0 - Posts/Blog
   ========================================================================== */

.post-item {
    margin-bottom: var(--nila-spacing-xl);
    background: var(--nila-bg);
    border-radius: var(--nila-radius-md);
    overflow: hidden;
    box-shadow: var(--nila-shadow-sm);
    transition: var(--nila-transition);
}

.post-item:hover {
    box-shadow: var(--nila-shadow-md);
    transform: translateY(-2px);
}

.post-thumbnail {
    position: relative;
    overflow: hidden;
}

.post-thumbnail img {
    width: 100%;
    transition: transform 0.5s ease;
}

.post-item:hover .post-thumbnail img {
    transform: scale(1.05);
}

.post-format-badge,
.sticky-badge {
    position: absolute;
    top: var(--nila-spacing-sm);
    right: var(--nila-spacing-sm);
    background: var(--nila-primary);
    color: white;
    padding: 0.35rem 0.75rem;
    border-radius: var(--nila-radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.post-content-wrapper {
    padding: var(--nila-spacing-lg);
}

.post-categories {
    margin-bottom: var(--nila-spacing-sm);
}

.post-category {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: var(--nila-primary);
    color: white;
    border-radius: var(--nila-radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-right: 0.5rem;
}

.post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: var(--nila-spacing-md);
}

.post-tag {
    padding: 0.25rem 0.75rem;
    background: var(--nila-bg-light);
    border-radius: var(--nila-radius-sm);
    font-size: 0.875rem;
    color: var(--nila-text);
}

.post-tag:hover {
    background: var(--nila-primary);
    color: white;
}

.read-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: var(--nila-spacing-xs) var(--nila-spacing-md);
    background: var(--nila-primary);
    color: white;
    border-radius: var(--nila-radius-sm);
    font-weight: 600;
    transition: var(--nila-transition);
}

.read-more-btn:hover {
    background: var(--nila-secondary);
    color: white;
}

/* Single Post */
.single-post {
    background: var(--nila-bg);
    padding: var(--nila-spacing-xl);
    border-radius: var(--nila-radius-md);
    box-shadow: var(--nila-shadow-sm);
}

.post-thumbnail-single {
    margin: calc(-1 * var(--nila-spacing-xl)) calc(-1 * var(--nila-spacing-xl)) var(--nila-spacing-lg);
    border-radius: var(--nila-radius-md) var(--nila-radius-md) 0 0;
}

.post-share-top,
.post-share-bottom {
    margin: var(--nila-spacing-lg) 0;
    padding: var(--nila-spacing-md);
    background: var(--nila-bg-light);
    border-radius: var(--nila-radius-md);
}

.nila-share-buttons {
    display: flex;
    gap: var(--nila-spacing-sm);
}

.nila-share-button {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--nila-primary);
    color: white;
    transition: var(--nila-transition);
}

.nila-share-button:hover {
    transform: translateY(-2px);
    box-shadow: var(--nila-shadow-md);
}

/* Post Navigation */
.post-navigation {
    margin-top: var(--nila-spacing-xl);
    padding-top: var(--nila-spacing-lg);
    border-top: 2px solid var(--nila-border);
}

.post-navigation .nav-links {
    display: flex;
    justify-content: space-between;
    gap: var(--nila-spacing-md);
}

.post-navigation a {
    flex: 1;
    padding: var(--nila-spacing-md);
    background: var(--nila-bg-light);
    border-radius: var(--nila-radius-md);
    transition: var(--nila-transition);
}

.post-navigation a:hover {
    background: var(--nila-primary);
    color: white;
}

.nav-subtitle {
    display: block;
    font-size: 0.875rem;
    color: var(--nila-text-light);
    margin-bottom: 0.5rem;
}

/* ==========================================================================
   11.0 - Comments
   ========================================================================== */

.comments-area {
    margin-top: var(--nila-spacing-xl);
    padding-top: var(--nila-spacing-xl);
    border-top: 2px solid var(--nila-border);
}

.comments-title {
    margin-bottom: var(--nila-spacing-lg);
}

.comment-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.comment-list .children {
    list-style: none;
    margin-left: var(--nila-spacing-xl);
}

.comment-body {
    padding: var(--nila-spacing-lg);
    background: var(--nila-bg-light);
    border-radius: var(--nila-radius-md);
    margin-bottom: var(--nila-spacing-md);
}

.comment-author {
    display: flex;
    align-items: center;
    gap: var(--nila-spacing-sm);
    margin-bottom: var(--nila-spacing-sm);
}

.comment-author img {
    border-radius: 50%;
}

.comment-metadata {
    font-size: 0.875rem;
    color: var(--nila-text-light);
    margin-bottom: var(--nila-spacing-sm);
}

.comment-content {
    margin-bottom: var(--nila-spacing-sm);
}

.reply {
    margin-top: var(--nila-spacing-sm);
}

/* Comment Form */
.comment-form {
    margin-top: var(--nila-spacing-xl);
}

.comment-form p {
    margin-bottom: var(--nila-spacing-md);
}

.comment-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    padding: var(--nila-spacing-sm);
    border: 1px solid var(--nila-border);
    border-radius: var(--nila-radius-sm);
    font-family: inherit;
}

.comment-form textarea {
    min-height: 150px;
    resize: vertical;
}

/* ==========================================================================
   17.0 - Utilities
   ========================================================================== */

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.d-none { display: none !important; }
.d-block { display: block !important; }
.d-flex { display: flex !important; }

.img-fluid {
    max-width: 100%;
    height: auto;
}

.clearfix::after {
    content: "";
    display: table;
    clear: both;
}

/* ==========================================================================
   18.0 - Responsive
   ========================================================================== */

@media screen and (max-width: 991px) {
    .main-navigation {
        display: none;
    }
    
    .menu-toggle {
        display: block;
    }
    
    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    h3 { font-size: 1.5rem; }
}

@media screen and (max-width: 768px) {
    :root {
        --nila-spacing-xl: 2rem;
        --nila-spacing-lg: 1.5rem;
    }
    
    .site-content {
        padding: var(--nila-spacing-lg) 0;
    }
    
    /* On mobile, all base columns become full width unless responsive class is specified */
    [class*="col-"]:not([class*="col-sm-"]):not([class*="col-md-"]):not([class*="col-lg-"]):not([class*="col-xl-"]) {
        flex: 0 0 100%;
        max-width: 100%;
    }
    
    h1 { font-size: 1.75rem; }
    h2 { font-size: 1.5rem; }
}
