/*
Theme Name: WPBlogging101 Theme
Theme URI: https://wpblogging101.com/
Author: Harpreet Kumar
Author URI: https://wpblogging101.com/
Description: A simple, lightning-fast, and lightweight custom WordPress theme.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: wpb101
*/

/* ==========================================
   1. LOCAL FONTS
   ========================================== */
   @font-face {
    font-family: 'Urbanist';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('./fonts/Urbanist-Regular.woff2') format('woff2');
}

@font-face {
    font-family: 'Urbanist';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('./fonts/Urbanist-Medium.woff2') format('woff2');
}

@font-face {
    font-family: 'Urbanist';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('./fonts/Urbanist-Bold.woff2') format('woff2');
}

@font-face {
    font-family: 'Urbanist';
    font-style: normal;
    font-weight: 900;
    font-display: swap;
    src: url('./fonts/Urbanist-Black.woff2') format('woff2');
}

@font-face {
    font-family: 'Urbanist';
    font-style: italic;
    font-weight: 900;
    font-display: swap;
    src: url('./fonts/Urbanist-BlackItalic.woff2') format('woff2');
}

/* ==========================================
   2. GLOBAL DESIGN SYSTEM (Edit everything here!)
   ========================================== */
:root {
    /* Fonts & Weights */
    --font-primary: 'Urbanist', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --weight-400: 400;
    --weight-500: 500;
    --weight-700: 700;
    --weight-900: 900;

    /* Base Text (Desktop) */
    --text-base-size: 18px;
    --text-line-height: 1.8;
    --text-letter-spacing: 0.2px;

    /* Heading Sizes (Desktop) */
--h1-size: 32px;
--h2-size: 26px;
--h3-size: 22px;
--h4-size: 18px;

    /* Colors */
    --color-bg-body: #ffffff;
    --color-text-main: #444444;
    --color-text-heading: #333333;
    --color-text-muted: #777777;
    --color-text-meta: #777777;
    --color-link: #ff3131;
    --color-border: #e5e7eb;
}

/* ==========================================
   3. MOBILE RESPONSIVE TYPOGRAPHY (Max 550px)
   ========================================== */
@media (max-width: 550px) {
    :root {
        /* Base Text (Mobile) */
        --text-base-size: 16px; 

        /* Heading Sizes (Mobile) */

--h1-size: 24px;
--h2-size: 23px;
--h3-size: 21px;
--h4-size: 18px;
}
.wpb101_post_meta {
    font-size: 13px !important;
}
}

/* ==========================================
   4. BASE STYLES & RESET
   ========================================== */
body {
    margin: 0;
    padding: 0;
    font-family: var(--font-primary);
    font-size: var(--text-base-size);
    font-weight: var(--weight-400);
    background-color: var(--color-bg-body);
    color: var(--color-text-main);
    line-height: var(--text-line-height);
    letter-spacing: var(--text-letter-spacing);
    -webkit-font-smoothing: antialiased;
}

.wpb101_container {
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 25px;
}

/* ==========================================
   5. TYPOGRAPHY (Headings, Paragraphs, Lists)
   ========================================== */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-primary);
    color: var(--color-text-heading);
    font-weight: var(--weight-900);
    margin-top: 24px;
    margin-bottom: 8px;
    line-height: 1.25;
}

h1 { font-size: var(--h1-size); }
h2 { font-size: var(--h2-size); }
h3 { font-size: var(--h3-size); }
h4 { font-size: var(--h4-size); }

p {
    margin-top: 0;
    margin-bottom: 24px;
}

ul, ol {
    margin-top: 0;
    margin-bottom: 24px;
    padding-left: 24px;
}

li {
    margin-bottom: 8px;
}

/* ==========================================
   6. MAIN CONTENT, POST CARDS & IMAGES
   ========================================== */
.wpb101_main {
    padding: 40px 0;
}

.wpb101_post_title {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: var(--h1-size);
}

.wpb101_post_title a {
    color: var(--color-text-heading);
    text-decoration: none;
}

.wpb101_post_title a:hover {
    color: var(--color-link);
}

.wpb101_post_meta {
    font-size: 14px;
    color: var(--color-text-meta);
    margin-bottom: 15px;
    padding-bottom: 15px;
}

.wpb101_post_content {
    margin-top: 20px;
}

.wpb101_post_content p {
    margin-bottom: 20px;
}

.wpb101_post_content a {
    color: var(--color-link);
    text-decoration: none;
    font-weight: var(--weight-700);
}

.wpb101_post_content a:hover {
    text-decoration: underline;
}

/* Responsive Image Handling */
.wpb101_post_content figure.wp-block-image {
    margin: 0 0 24px 0;
    max-width: 100%;
}

.wpb101_post_content img {
    max-width: 100%;
    height: auto;
    display: block;
    border-radius: 2px;
}

.wpb101_post_content figcaption {
    text-align: center;
    font-size: 14px;
    color: var(--color-text-muted);
    margin-top: 8px;
}

/* ==========================================
   7. GUTENBERG BUTTONS
   ========================================== */
.wp-block-buttons {
    margin-bottom: 24px;
}

.wp-block-button__link,
.wp-element-button {
    background-color: var(--color-link);
    color: #ffffff !important;
    border-radius: 2px;
    padding: 12px 24px;
    text-decoration: none !important;
    font-weight: var(--weight-700);
    display: inline-block;
    transition: background-color 0.2s ease, color 0.2s ease;
    border: none;
    font-family: var(--font-primary);
    font-size: 16px;
}

.wp-block-button__link:hover,
.wp-element-button:hover {
    background-color: var(--color-text-heading);
    color: #ffffff !important;
}

/* ==========================================
   8. GUTENBERG TABLES
   ========================================== */
.wp-block-table {
    margin: 30px 0 30px 0;
    overflow-x: auto; /* Ensures tables don't break mobile layout */
    max-width: 950px;
}

.wp-block-table table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.wp-block-table th,
.wp-block-table td {
    padding: 12px 16px;
    border: 1px solid var(--color-border);
    font-size: 0.95em;
}

.wp-block-table th {
    background-color: #f8fafc;
    color: var(--color-text-heading);
    font-weight: var(--weight-700);
}