/*
Theme Name: SanaDigest Theme
Theme URI: https://sanadigest.com
Description: A custom, professional theme for SanaDigest, mirroring Sanalyslab's minimalist aesthetic.
Version: 2.0.0
Author: SanaDigest Team
Text Domain: sanadigest-theme
*/

:root {
    /* Sanalyslab Palette */
    --color-primary: #333333; /* Dark Grey/Black for text/headings */
    --color-secondary: #74bf44; /* Fresh Green (Sanalyslab accent) */
    --color-secondary-hover: #5da035;
    --color-text: #555555; /* Soft Grey for body text */
    --color-light-bg: #f9f9f9;
    --color-border: #e5e5e5;
    --color-white: #ffffff;
    --color-topbar-bg: #333333;
    --color-topbar-text: #ffffff;

    /* Typography */
    --font-primary: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    --font-size-base: 16px;
    
    /* Spacing */
    --container-width: 1200px;
    --gutter: 15px;
}

/* =Reset & Base
-------------------------------------------------------------- */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: var(--font-primary);
    font-size: var(--font-size-base);
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-white);
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--color-primary);
    font-weight: 700;
    margin: 0 0 1rem;
    line-height: 1.2;
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--color-secondary);
}

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

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

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

/* =Buttons
-------------------------------------------------------------- */
.btn {
    display: inline-block;
    padding: 12px 30px;
    background-color: var(--color-secondary);
    color: var(--color-white);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 14px;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.btn:hover {
    background-color: var(--color-secondary-hover);
    color: var(--color-white);
    text-decoration: none;
    transform: translateY(-1px);
}

.btn-primary {
    background-color: var(--color-secondary);
}

/* =Forms
-------------------------------------------------------------- */
input[type="text"],
input[type="email"],
textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--color-border);
    border-radius: 4px;
    font-size: 14px;
}

input:focus {
    outline: none;
    border-color: var(--color-secondary);
}

/* =Header
-------------------------------------------------------------- */
.top-bar {
    background-color: var(--color-topbar-bg);
    color: var(--color-topbar-text);
    padding: 8px 0;
    font-size: 13px;
}

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

.top-contact a {
    color: var(--color-topbar-text);
    margin-right: 15px;
}

.top-contact .sep {
    margin-right: 15px;
    opacity: 0.5;
}

.site-header {
    background: var(--color-white);
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

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

.site-title {
    font-size: 24px;
    letter-spacing: 1px;
    margin: 0;
}

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

.site-title .highlight {
    color: #999;
}

.main-navigation ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 30px;
}

.main-navigation a {
    font-weight: 500;
    font-size: 15px;
    text-transform: uppercase;
}

.cart-icon {
    position: relative;
    display: flex;
    align-items: center;
    color: var(--color-primary);
}

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

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 4px;
}

.mobile-menu-toggle .bar {
    width: 25px;
    height: 2px;
    background-color: var(--color-primary);
}

/* =Homepage
-------------------------------------------------------------- */
.hero-section {
    background-color: #f4f4f4;
    padding: 100px 0;
    position: relative;
    margin-bottom: 0;
}

.hero-title {
    font-size: 48px;
    margin-bottom: 20px;
    color: var(--color-primary);
}

.hero-subtitle {
    font-size: 18px;
    max-width: 600px;
    margin: 0 auto 30px;
    color: var(--color-text);
}

.usp-bar {
    background-color: var(--color-white);
    border-bottom: 1px solid #eee;
    padding: 20px 0;
}

.usp-grid {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 20px;
}

.usp-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
    color: var(--color-primary);
}

.usp-icon {
    font-size: 20px;
}

.video-section {
    padding: 80px 0;
    background-color: var(--color-white);
}

.section-title {
    font-size: 32px;
    margin-bottom: 10px;
    color: var(--color-primary);
}

.section-desc {
    max-width: 600px;
    margin: 0 auto 40px;
    color: #777;
}

.video-wrapper {
    max-width: 800px;
    margin: 0 auto;
    aspect-ratio: 16 / 9;
    background-color: #000;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}

.video-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: #333;
}

.play-button {
    font-size: 48px;
    margin-bottom: 10px;
    cursor: pointer;
}

.product-highlight {
    padding: 80px 0;
    background-color: #f9f9f9;
}

.highlight-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.image-box {
    background: #fff;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #eee;
    color: #ccc;
}

.highlight-features {
    list-style: none;
    padding: 0;
    margin: 20px 0 30px;
}

.highlight-features li {
    margin-bottom: 10px;
    padding-left: 25px;
    position: relative;
}

.highlight-features li:before {
    content: "✓";
    color: var(--color-secondary);
    position: absolute;
    left: 0;
    font-weight: bold;
}

.testimonials-section {
    padding: 80px 0;
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.testimonial-card {
    background: #fff;
    padding: 30px;
    border: 1px solid #eee;
    border-radius: 8px;
    text-align: center;
}

.stars {
    color: #ffc107;
    margin-bottom: 15px;
    letter-spacing: 2px;
}

.quote {
    font-style: italic;
    margin-bottom: 20px;
    color: #555;
}

.author {
    font-weight: bold;
    color: var(--color-primary);
}

/* =Science Section
-------------------------------------------------------------- */
.science-section {
    padding: 80px 0;
    background-color: var(--color-white);
    border-bottom: 1px solid #f0f0f0;
}

.science-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    margin-top: 40px;
    text-align: center;
}

.science-item {
    padding: 20px;
}

.science-icon {
    font-size: 48px;
    margin-bottom: 20px;
    display: inline-block;
    background: #f4fcf4;
    width: 100px;
    height: 100px;
    line-height: 100px;
    border-radius: 50%;
    color: var(--color-secondary);
}

/* =WooCommerce Single Product Enhancements
-------------------------------------------------------------- */
.product-page-container {
    padding-top: 40px;
    padding-bottom: 40px;
}

.product-top-section {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
    margin-bottom: 60px;
}

.product-gallery-column {
    flex: 1;
    min-width: 300px;
}

.product-info-column {
    flex: 1;
    min-width: 300px;
}

/* Override default WooCommerce float layout */
.woocommerce div.product div.images,
.woocommerce div.product div.summary {
    float: none !important;
    width: 100% !important;
    padding: 0 !important;
}

.woocommerce div.product .product_title {
    font-size: 32px;
    color: var(--color-primary);
    margin-bottom: 10px;
    line-height: 1.2;
}

.woocommerce div.product .price {
    color: var(--color-secondary);
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
    display: block;
}

.woocommerce-product-details__short-description {
    color: #666;
    margin-bottom: 30px;
    font-size: 16px;
}

.product-guarantees {
    display: flex;
    gap: 20px;
    margin-top: 25px;
    padding-top: 25px;
    border-top: 1px solid #eee;
}

.guarantee-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #555;
}

.woocommerce-tabs {
    margin-top: 60px;
    border-top: 1px solid #eee;
    padding-top: 40px;
}

.woocommerce div.product .woocommerce-tabs ul.tabs {
    padding: 0;
    margin: 0 0 20px;
    border: none;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li {
    background: transparent;
    border: none;
    margin: 0 20px 0 0;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li a {
    padding: 10px 0;
    font-weight: 700;
    color: #999;
    font-size: 16px;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active a {
    color: var(--color-primary);
    border-bottom: 2px solid var(--color-secondary);
}

.woocommerce div.product .woocommerce-tabs .panel {
    border: none;
    box-shadow: none;
    padding: 0;
}

/* =WooCommerce General Overrides */
.woocommerce a.button, 
.woocommerce button.button, 
.woocommerce input.button,
.woocommerce #respond input#submit {
    background-color: var(--color-secondary) !important;
    color: var(--color-white) !important;
    border-radius: 4px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    padding: 12px 24px !important;
}

.woocommerce a.button:hover, 
.woocommerce button.button:hover, 
.woocommerce input.button:hover {
    background-color: var(--color-secondary-hover) !important;
}

.woocommerce-message, 
.woocommerce-info {
    border-top-color: var(--color-secondary);
}

.onsale {
    background-color: var(--color-secondary) !important;
}

/* =Video Container (Responsive Embed) */
.video-container {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 */
    height: 0;
    overflow: hidden;
    max-width: 100%;
    background: #000;
}

.video-container iframe,
.video-container object,
.video-container embed {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* =Footer
-------------------------------------------------------------- */
.site-footer {
    background-color: #222;
    color: #ccc;
    font-size: 14px;
    margin-top: 0;
}

.footer-top {
    padding: 60px 0;
}

.footer-widgets {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
}

.widget-title {
    color: #fff;
    font-size: 16px;
    text-transform: uppercase;
    margin-bottom: 20px;
    letter-spacing: 0.5px;
}

.footer-widget p {
    margin-bottom: 15px;
    line-height: 1.6;
}

.footer-widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-widget li {
    margin-bottom: 10px;
}

.footer-widget a {
    color: #ccc;
}

.footer-widget a:hover {
    color: var(--color-secondary);
}

.newsletter-form {
    display: flex;
    gap: 10px;
}

.footer-bottom {
    background-color: #1a1a1a;
    padding: 20px 0;
    border-top: 1px solid #333;
}

.footer-bottom-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.payment-methods span {
    background: #fff;
    color: #333;
    padding: 2px 6px;
    border-radius: 2px;
    font-size: 12px;
    font-weight: bold;
    margin-left: 5px;
}

/* =Responsive Utilities
-------------------------------------------------------------- */
@media (max-width: 768px) {
    .container {
        padding: 0 20px;
    }

    .main-navigation {
        display: none;
        width: 100%;
        position: absolute;
        top: 100%;
        left: 0;
        background: #fff;
        padding: 20px;
        box-shadow: 0 4px 6px rgba(0,0,0,0.1);
        z-index: 1000;
        border-top: 1px solid #eee;
    }

    .main-navigation.toggled {
        display: block;
    }
    
    .main-navigation ul {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }
    
    .top-bar {
        text-align: center;
    }
    
    .top-bar-inner {
        flex-direction: column;
        gap: 5px;
    }

    .header-container {
        flex-wrap: wrap;
    }

    .hero-title { font-size: 32px; }
    .highlight-grid { grid-template-columns: 1fr; gap: 30px; }
    .usp-grid { flex-direction: column; align-items: center; }
}
