/*
Theme Name: HPL
Theme URI: https://www.hpl.web.id
Author: Yudi
Description: Super fast, SEO Friendly, Rank Math Compatible, Mobile First, Core Web Vitals Optimized.
Version: 2.1
Text Domain: hpl
*/

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

/* --- 1. VARIABLES & RESET --- */
:root {
    --bg-color: #000000;
    --text-color: #e0e0e0;
    --primary-color: #FACC15;
    --accent-color: #f39c12;
    --link-color: #FACC15;
    --container-width: 900px;
    --spacing: 20px;
    --card-padding: 30px;
    --font-stack: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --glass-bg: rgba(20, 20, 20, 0.8);
    --glass-border: rgba(250, 204, 21, 0.2);
    --glass-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

@media (max-width: 600px) {
    :root {
        --spacing: 15px;
        --card-padding: 15px;
    }
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: var(--font-stack);
    line-height: 1.7;
    color: var(--text-color);
    background: var(--bg-color);
    font-size: 16px;
    overflow-x: hidden;
}

/* --- 2. LAYOUT & HEADER --- */
.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 var(--spacing);
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1rem 0;
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}

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

.site-title a { 
    text-decoration: none; 
    color: var(--primary-color); 
    font-weight: 800; 
    font-size: 1.6rem;
    letter-spacing: -0.5px;
}

.main-navigation ul {
    list-style: none;
    display: flex;
    gap: 20px;
}

.main-navigation a {
    color: #a4b0be;
    font-weight: 600;
    font-size: 0.95rem;
    transition: color 0.3s;
}

.main-navigation a:hover {
    color: var(--primary-color);
    text-decoration: none;
}

/* --- 3. TYPOGRAPHY & ELEMENTS --- */
h1, h2, h3 { margin-bottom: 0.8rem; line-height: 1.2; font-weight: 700; color: #ffffff; }
h1 { font-size: 2.2rem; letter-spacing: -0.5px; } 
h2 { font-size: 1.8rem; }
h3 { font-size: 1.5rem; }

@media (max-width: 768px) {
    h1 { font-size: 1.8rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.3rem; }
}

a { color: var(--link-color); text-decoration: none; }
a:hover { text-decoration: underline; }

p { margin-bottom: 1.5rem; }

img { max-width: 100%; height: auto; display: block; }
iframe { max-width: 100%; aspect-ratio: 16/9; }

/* Breadcrumbs (Rank Math) fallback cleanup */
.rank-math-breadcrumb {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 0.8rem;
    display: none; /* Hide old breadcrumb style if necessary, we use the new one now */
}
.rank-math-breadcrumb a { color: #666; text-decoration: none; }

/* --- 4. ACCESSIBILITY (Screen Reader) --- */
.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;
}
.skip-link:focus {
    background-color: #f1f1f1;
    border-radius: 3px;
    box-shadow: 0 0 2px 2px rgba(0,0,0,0.6);
    clip: auto !important; clip-path: none;
    color: var(--primary-color);
    display: block; font-size: 1rem; font-weight: 700;
    height: auto; left: 5px; top: 5px;
    padding: 15px 23px; text-decoration: none; width: auto; z-index: 100000;
}

/* --- 5. POSTS GRID & ARCHIVES --- */
.premium-heading {
    font-size: 1.8rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 35px;
    position: relative;
    display: inline-block;
}

@media (max-width: 768px) {
    .premium-heading { font-size: 1.4rem; margin-bottom: 25px; }
}

.premium-heading::after {
    background: linear-gradient(135deg, rgba(250, 204, 21, 0.1) 0%, rgba(243, 156, 18, 0.1) 100%);
}

.premium-archive {
    background: linear-gradient(135deg, rgba(250, 204, 21, 0.05) 0%, rgba(20, 20, 20, 0.8) 100%);
}

.post-card {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    padding: 30px;
    border-radius: 24px;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    margin-bottom: 30px;
    position: relative;
    overflow: hidden;
}

.post-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 50px rgba(0,0,0,0.8);
    border-color: rgba(250, 204, 21, 0.5);
}

.post-card .post-title a {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s;
}

.post-card:hover .post-title a {
    color: var(--primary-color);
}

.read-more-btn {
    transition: all 0.3s ease;
}

.read-more-btn:hover {
    gap: 12px !important;
    text-decoration: none !important;
}

.pagination-wrapper .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    margin: 0 5px;
    border-radius: 50%;
    background: #111;
    color: #a4b0be;
    font-weight: 700;
    transition: all 0.3s;
    border: 1px solid #333;
}

.pagination-wrapper .page-numbers.current {
    background: var(--primary-color);
    color: #000;
    border-color: var(--primary-color);
    box-shadow: 0 8px 15px rgba(250, 204, 21, 0.2);
}

.pagination-wrapper .page-numbers:hover:not(.current) {
    background: var(--primary-color);
    color: #000;
    border-color: var(--primary-color);
    text-decoration: none;
}

/* Fallback for legacy post items */
.post-item { 
    margin-bottom: 3rem; 
    padding: 30px;
    background: #111;
    border-radius: 15px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.5);
    border: 1px solid #333;
}

/* --- 6. RELATED POSTS --- */
.related-posts {
    margin-top: 3rem; padding-top: 2rem; border-top: 4px solid #333;
}
.related-posts h3 {
    font-size: 1.4rem; margin-bottom: 1.5rem;
    border-left: 5px solid var(--primary-color); padding-left: 10px;
}
.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.5rem;
}
.related-item {
    background: #151515; padding: 1rem; border-radius: 8px; border: 1px solid #333;
}
.related-item h4 { font-size: 1.1rem; margin-bottom: 0.5rem; line-height: 1.4; }
.related-item h4 a { color: var(--text-color); }
.related-item h4 a:hover { color: var(--primary-color); }

/* --- 7. SEARCH PAGE --- */
.search-header {
    background: #1a1a1a; padding: 2rem; border-radius: 8px;
    margin-bottom: 2rem; border-left: 5px solid var(--primary-color);
}
.search-no-result {
    padding: 2rem; background: #2f0f0f; border: 1px solid #ff4d4d;
    border-radius: 8px; margin-bottom: 2rem; color: #ff9999;
}

/* --- 8. FOOTER --- */
.site-footer {
    margin-top: 5rem;
    padding: 4rem 0 2rem;
    background: #0a0a0a;
    color: #a4b0be;
    border-top: 1px solid #333;
}

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

.footer-column h4 {
    color: #ffffff;
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
}

.footer-column ul {
    list-style: none;
}

.footer-column ul li {
    margin-bottom: 0.8rem;
}

.footer-column ul a {
    color: #a4b0be;
    font-size: 0.95rem;
    transition: color 0.3s;
}

.footer-column ul a:hover {
    color: var(--primary-color);
    text-decoration: none;
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid #333;
    text-align: center;
    font-size: 0.9rem;
}

.seo-tagline {
    font-style: italic;
    color: #b2bec3;
    margin-top: 10px;
}

/* Floating Footer Bar */
.floating-footer-bar {
    position: fixed;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    width: 90%;
    max-width: 450px;
    pointer-events: none;
}

.floating-content {
    background: rgba(20, 20, 20, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(250, 204, 21, 0.3);
    border-radius: 50px;
    padding: 10px 15px;
    display: flex;
    justify-content: space-around;
    align-items: center;
    box-shadow: 0 15px 45px rgba(0,0,0,0.8);
    pointer-events: auto;
}

.floating-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #a4b0be;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    flex: 1;
}

.floating-item span {
    font-size: 0.65rem;
    font-weight: 700;
    margin-top: 2px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.floating-item:hover {
    color: var(--primary-color);
    transform: translateY(-3px);
    text-decoration: none;
}

.floating-item.calc-btn {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    color: #000;
    padding: 10px 18px;
    border-radius: 30px;
    flex-direction: row;
    gap: 8px;
    flex: 1.5;
    margin: 0 5px;
    box-shadow: 0 8px 20px rgba(250, 204, 21, 0.3);
}

.floating-item.calc-btn span {
    font-size: 0.8rem;
    margin-top: 0;
}

.floating-item.calc-btn:hover {
    background: linear-gradient(135deg, var(--accent-color) 0%, var(--primary-color) 100%);
    box-shadow: 0 12px 25px rgba(250, 204, 21, 0.4);
    color: #000;
}

@media (max-width: 400px) {
    .floating-item span { display: none; }
    .floating-item.calc-btn span { display: block; font-size: 0.75rem; }
    .floating-item.calc-btn { padding: 5px 7px; }
}

/* --- Responsive Grid Utilities --- */
.pregnancy-images-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 40px 0;
}

.responsive-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

@media (max-width: 600px) {
    .pregnancy-images-grid, .responsive-grid-2 {
        grid-template-columns: 1fr !important;
    }
}

/* --- Astrology Theme Utilities --- */
.gradient-text {
    background: linear-gradient(90deg, #FACC15 0%, #f39c12 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.glassmorphism {
    background: rgba(30, 30, 30, 0.7);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(250, 204, 21, 0.2);
    border-radius: 20px;
    box-shadow: rgba(0, 0, 0, 0.5) 0px 4px 12px;
}

.btn-primary {
    padding: 12px 30px;
    background: var(--primary-color);
    color: #000 !important;
    border-radius: 50px;
    text-decoration: none !important;
    font-weight: 700;
    transition: all 0.3s;
    display: inline-block;
    box-shadow: 0 10px 20px rgba(250, 204, 21, 0.2);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px rgba(250, 204, 21, 0.4);
}

.btn-secondary {
    padding: 12px 30px;
    background: rgba(255,255,255,0.05);
    color: var(--text-color) !important;
    border-radius: 50px;
    text-decoration: none !important;
    font-weight: 700;
    border: 1px solid rgba(250, 204, 21, 0.3);
    transition: all 0.3s;
    display: inline-block;
}

.btn-secondary:hover {
    background: rgba(250, 204, 21, 0.1);
    color: var(--primary-color) !important;
}

.hpht-form .input-group {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
}

.hpht-form input {
    flex: 1;
    padding: 14px 20px;
    border: 2px solid #333;
    border-radius: 12px;
    font-size: 1rem;
    background: #111;
    color: #fff;
    transition: all 0.3s ease;
}

.hpht-form input:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 4px rgba(250, 204, 21, 0.1);
}

/* Dual Calculator Styling */
.hpht-calculator-wrapper {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 40px;
    box-shadow: var(--glass-shadow);
    margin: 20px 0;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
}

.hpht-calculator-container {
    padding: 10px 0;
}

.btn-calculate.btn-alt {
    background: var(--accent-color);
}

.btn-calculate.btn-alt:hover {
    background: #e67e22;
}

@media (max-width: 600px) {
    .hpht-calculator-wrapper {
        padding: 2px 1px;
    }
}

/* Social Share Buttons */
.share-grid {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.share-btn {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.share-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 18px rgba(0,0,0,0.12);
    color: #fff;
    text-decoration: none;
}

.share-btn.wa { background: #25D366; }
.share-btn.fb { background: #1877F2; }
.share-btn.story { background: linear-gradient(45deg, #f09433 0%,#e6683c 25%,#dc2743 50%,#cc2366 75%,#bc1888 100%); }
.share-btn.copy { background: #636e72; }

.share-btn svg {
    transition: transform 0.3s;
}

.share-btn:hover svg {
    transform: scale(1.1);
}

.btn-calculate {
    background: var(--primary-color);
    color: #000;
    border: none;
    padding: 14px 28px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-calculate:hover {
    background: var(--accent-color);
    transform: translateY(-2px);
}

.helper-text {
    font-size: 0.85rem;
    color: #888;
    margin: 0;
}

@media (max-width: 600px) {
    .hpht-form .input-group {
        flex-direction: column;
    }
    .btn-calculate {
        width: 100%;
    }
}

/* --- Breadcrumbs --- */
.breadcrumb-nav {
    background: rgba(10, 10, 10, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(250, 204, 21, 0.2);
}

.breadcrumb-list {
    padding: 12px 0 !important;
}

.breadcrumb-item a:hover {
    color: var(--primary-color) !important;
    text-decoration: underline !important;
}

.breadcrumb-item .current {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 300px;
    display: inline-block;
}

@media (max-width: 768px) {
    .breadcrumb-item .current {
        max-width: 150px;
    }
    .breadcrumb-list {
        font-size: 0.75rem !important;
    }
}

/* --- Exploration Grid --- */
.exploration-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.exploration-item {
    background: rgba(20, 20, 20, 0.8) !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.5);
    display: block;
    padding: 20px;
    text-align: center;
    font-weight: 700;
    color: var(--primary-color);
    font-size: 0.95rem;
    border-radius: 15px;
    border: 1px solid #333;
    transition: all 0.3s ease;
    text-decoration: none !important;
}

.exploration-item:hover {
    transform: translateY(-5px);
    background: #111 !important;
    box-shadow: 0 10px 25px rgba(250, 204, 21, 0.2);
    color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
}

@media (max-width: 900px) {
    .exploration-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .exploration-section {
        padding: 30px 15px !important;
        border-radius: 20px !important;
    }
    .exploration-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    /* Mobile Typography Overrides */
    h1 { font-size: 1.7rem !important; }
    h2 { font-size: 1.4rem !important; }
    h3 { font-size: 1.2rem !important; }
    p { font-size: 0.95rem !important; line-height: 1.6 !important; }
}