/*
 Theme Name:   Story Hippo
 Theme URI:    https://story-hippo.com/
 Description:  Story Hippo child theme
 Author:       Your Name
 Author URI:   https://your-website.com
 Template:     bam
 Version:      1.1.0
 License:      GPL v2 or later
 License URI:  http://www.gnu.org/licenses/gpl-2.0.html
 Text Domain:  story-hippo
*/

/* Compact Design Overrides */

/* Reduce Site Content Padding */
.site-content {
    padding: 20px 0;
}

/* Reduce Post Spacing */
.bam-entry {
    margin-bottom: 30px;
}

/* Reduce Widget Spacing */
.widget {
    margin: 0 0 30px;
}

/* Reduce Inner Padding for Separate Containers */
body.separate-containers .blog-entry-inner,
body.separate-containers.single .site-main,
body.separate-containers.page .site-main {
    padding: 15px;
}

/* Reduce Sidebar Widget Padding */
body.separate-containers #secondary .widget {
    padding: 15px;
}

/* Reduce Heading Margins */
h1 {
    margin: 0.3em 0;
}

h2 {
    margin: 0.4em 0;
}

h3 {
    margin: 0.5em 0;
}

/* Compact Widget Titles */
.widget-title {
    margin: 0 0 10px;
    font-size: 1.1rem;
}

/* -------------------------------------------------------------------------- */
/* Vogue India Inspired Menu (Overrides) */
/* -------------------------------------------------------------------------- */

/* 1. Main Navigation Container - White Background */
.site-header.default-style .main-navigation,
.site-header.horizontal-style #site-header-inner-wrap,
.site-header.horizontal-style .main-navigation {
    background: #ffffff !important;
    border-bottom: 1px solid #eeeeee;
}

/* 2. Top Level Menu Items - Black Text */
.main-navigation ul li a,
.site-header.default-style .main-navigation ul li a,
.site-header.horizontal-style .main-navigation ul li a {
    color: #000000 !important;
    font-weight: 700;
    /* Make it bold like Vogue */
    text-transform: uppercase;
}

/* 3. Hover State - Red Accent */
.main-navigation ul li a:hover,
.site-header.default-style .main-navigation ul li a:hover,
.site-header.horizontal-style .main-navigation ul li a:hover,
.main-navigation .current-menu-item>a,
.site-header.default-style .main-navigation .current-menu-item>a {
    color: #e3000f !important;
    /* Vogue Red */
    background: transparent !important;
    /* Remove dark bg if any */
}

/* 4. Dropdown Menus - White Background, Black Text */
.main-navigation ul ul,
.site-header.default-style .main-navigation ul ul,
.site-header.horizontal-style .main-navigation ul ul {
    background: #ffffff !important;
    border: 1px solid #eeeeee;
    /* Light border definition */
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    /* Subtle shadow, not heavy */
}

.main-navigation ul ul li a,
.site-header.default-style .main-navigation ul ul li a,
.site-header.horizontal-style .main-navigation ul ul li a {
    color: #000000 !important;
    border-bottom: 1px solid #f9f9f9;
    /* Subtle separator */
}

.main-navigation ul ul li a:hover,
.site-header.default-style .main-navigation ul ul li a:hover,
.site-header.horizontal-style .main-navigation ul ul li a:hover {
    color: #e3000f !important;
    background: #fdfdfd !important;
    /* Very slight grey on hover */
}

/* 5. Mobile Menu - Ensure Visibility */
.mobile-navigation {
    background: #ffffff !important;
    border-bottom: 1px solid #eeeeee;
}

.mobile-navigation ul li a {
    color: #000000 !important;
    border-bottom: 1px solid #f1f1f1;
}

/* Mobile Toggle Button color */
.menu-toggle,
.menu-toggle i.fas {
    color: #000000 !important;
}

/* 6. Site Title/Logo adjustments for white background */
.site-title a {
    color: #000000 !important;
}

.site-description {
    color: #333333 !important;
}

/* Horizontal Story Hippo logo */
.story-hippo-default-logo {
    display: block;
    line-height: 0;
}

.story-hippo-default-logo img {
    display: block;
    width: auto;
    max-width: min(320px, 55vw);
    max-height: 52px;
    object-fit: contain;
}

@media screen and (max-width: 480px) {
    .story-hippo-default-logo img {
        max-width: 230px;
        max-height: 46px;
    }
}

/* 7. Search Icon */
.bam-search-button-icon {
    color: #000000 !important;
}

/* -------------------------------------------------------------------------- */
/* Sticky Menu Implementation */
/* -------------------------------------------------------------------------- */
/* Apply sticky to the main header container so it sticks within the body/page */
.site-header {
    position: -webkit-sticky;
    /* Safari */
    position: sticky;
    top: 0;
    z-index: 9999;
    width: 100%;
    background: #ffffff;
    /* Ensure background is white so content doesn't show through */
}

/* Ensure admin bar doesn't cover it if logged in */
body.admin-bar .site-header {
    top: 32px;
}

@media screen and (max-width: 782px) {

    body.admin-bar .site-header {
        top: 46px;
    }
}

/* -------------------------------------------------------------------------- */
/* Story Hippo editorial typography and homepage                              */
/* -------------------------------------------------------------------------- */

:root {
    --story-ink: #080808;
    --story-muted: #6c6c6c;
    --story-rule: #d9d9d9;
    --story-accent: #e3000f;
    --story-display: "Playfair Display", Georgia, "Times New Roman", serif;
    --story-sans: "Montserrat", "Helvetica Neue", Arial, sans-serif;
}

body {
    color: var(--story-ink);
    font-family: var(--story-sans);
}

h1,
h2,
h3,
h4,
h5,
h6,
.entry-title {
    color: var(--story-ink);
    font-family: var(--story-display);
    font-weight: 600;
    letter-spacing: -0.025em;
    line-height: 1.15;
}

.single .entry-title,
.page-entry-title {
    font-family: var(--story-display);
    font-weight: 600;
    letter-spacing: -0.025em;
    line-height: 1.14;
}

a {
    transition: color 160ms ease;
}

.main-navigation ul li a {
    font-family: var(--story-sans);
    font-size: 12px;
    letter-spacing: 0.1em;
}

.site-header.horizontal-style #site-header-inner-wrap {
    border-bottom: 1px solid var(--story-rule);
}

.site-header.horizontal-style .site-branding-inner,
.site-header.horizontal-style .menu-toggle {
    height: 74px;
    line-height: 74px;
}

body.home .site-content {
    padding: 0;
}

body.home .site-content > .container {
    max-width: none;
    padding: 0;
    width: 100%;
}

.story-hippo-home {
    background: #fff;
    margin: 0 auto;
    max-width: 1500px;
    padding: 44px 48px 96px;
}

.story-hippo-home a {
    color: inherit;
    text-decoration: none;
}

.story-hippo-home a:hover,
.story-hippo-home a:focus {
    color: var(--story-accent);
}

.story-hippo-hero {
    border-bottom: 1px solid var(--story-rule);
    padding-bottom: 64px;
}

.story-hippo-hero-grid {
    align-items: start;
    display: grid;
    gap: clamp(22px, 2.4vw, 40px);
    grid-template-columns: minmax(210px, 0.78fr) minmax(0, 1.75fr) minmax(230px, 0.82fr);
}

.story-hippo-hero-left {
    display: grid;
    gap: 42px;
}

.story-hippo-card-copy,
.story-hippo-lead-copy {
    text-align: center;
}

.story-hippo-image-link {
    background: #f1f1f1;
    display: block;
    overflow: hidden;
}

.story-hippo-card-image {
    display: block;
    height: 100%;
    object-fit: cover;
    transition: transform 300ms ease;
    width: 100%;
}

.story-hippo-image-link:hover .story-hippo-card-image {
    transform: scale(1.015);
}

.story-hippo-side-card .story-hippo-image-link {
    aspect-ratio: 4 / 3;
}

.story-hippo-side-card .story-hippo-card-copy {
    padding: 16px 5px 0;
}

.story-hippo-kicker {
    display: inline-block;
    font-family: var(--story-sans);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.13em;
    line-height: 1.3;
    margin-bottom: 9px;
    text-transform: uppercase;
}

.story-hippo-side-title {
    font-family: var(--story-sans);
    font-size: clamp(17px, 1.35vw, 21px);
    font-weight: 500;
    letter-spacing: -0.025em;
    line-height: 1.22;
    margin: 0;
}

.story-hippo-byline {
    color: var(--story-muted);
    font-family: var(--story-sans);
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.14em;
    line-height: 1.5;
    margin: 14px 0 0;
    text-transform: uppercase;
}

.story-hippo-lead .story-hippo-image-link {
    aspect-ratio: 4 / 3;
}

.story-hippo-lead-copy {
    margin: 0 auto;
    max-width: 780px;
    padding: 19px 24px 0;
}

.story-hippo-lead-title {
    font-family: var(--story-display);
    font-size: clamp(38px, 4vw, 66px);
    font-weight: 600;
    letter-spacing: -0.035em;
    line-height: 1.02;
    margin: 0;
}

.story-hippo-lead-excerpt {
    color: #3f3f3f;
    font-family: var(--story-sans);
    font-size: 14px;
    line-height: 1.65;
    margin: 18px auto 0;
    max-width: 640px;
}

.story-hippo-hero-right {
    border-top: 3px solid var(--story-ink);
}

.story-hippo-rail-heading {
    border-bottom: 1px solid var(--story-rule);
    font-family: var(--story-display);
    font-size: 28px;
    letter-spacing: -0.03em;
    margin: 0;
    padding: 13px 0;
}

.story-hippo-rail-card {
    border-bottom: 1px solid var(--story-rule);
    display: grid;
    gap: 14px;
    grid-template-columns: minmax(0, 1fr) 82px;
    padding: 20px 0;
}

.story-hippo-rail-card h3 {
    font-family: var(--story-sans);
    font-size: 15px;
    font-weight: 500;
    letter-spacing: -0.02em;
    line-height: 1.3;
    margin: 0;
}

.story-hippo-rail-card .story-hippo-byline {
    font-size: 9px;
    margin-top: 10px;
}

.story-hippo-rail-image {
    align-self: start;
    aspect-ratio: 4 / 5;
    background: #f1f1f1;
    display: block;
    overflow: hidden;
}

.story-hippo-section {
    padding-top: 76px;
}

.story-hippo-section-header {
    align-items: center;
    border-bottom: 1px solid var(--story-rule);
    border-top: 3px solid var(--story-ink);
    display: flex;
    justify-content: center;
    margin-bottom: 32px;
    padding: 19px 0 21px;
    text-align: center;
}

.story-hippo-section-header h2 {
    font-family: var(--story-display);
    font-size: clamp(42px, 5vw, 70px);
    letter-spacing: -0.055em;
    line-height: 1;
    margin: 0;
}

.story-hippo-latest-grid {
    display: grid;
    gap: clamp(24px, 2.4vw, 40px);
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.story-hippo-latest-card .story-hippo-image-link {
    aspect-ratio: 4 / 3;
}

.story-hippo-latest-card .story-hippo-card-copy {
    padding: 17px 14px 0;
}

.story-hippo-latest-card h3 {
    font-family: var(--story-sans);
    font-size: clamp(20px, 1.8vw, 28px);
    font-weight: 500;
    letter-spacing: -0.035em;
    line-height: 1.18;
    margin: 0;
}

.story-hippo-more-grid {
    display: grid;
    gap: 0 48px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.story-hippo-more-card {
    align-items: center;
    border-bottom: 1px solid var(--story-rule);
    display: grid;
    gap: 22px;
    grid-template-columns: minmax(145px, 0.42fr) minmax(0, 1fr);
    padding: 24px 0;
}

.story-hippo-more-card:first-child,
.story-hippo-more-card:nth-child(2) {
    border-top: 1px solid var(--story-rule);
}

.story-hippo-more-image {
    aspect-ratio: 4 / 3;
    background: #f1f1f1;
    display: block;
    overflow: hidden;
}

.story-hippo-more-card h3 {
    font-family: var(--story-sans);
    font-size: clamp(17px, 1.6vw, 23px);
    font-weight: 500;
    letter-spacing: -0.025em;
    line-height: 1.24;
    margin: 0;
}

.story-hippo-more-card time {
    color: var(--story-muted);
    display: block;
    font-size: 10px;
    letter-spacing: 0.1em;
    margin-top: 12px;
    text-transform: uppercase;
}

.story-hippo-image-fallback {
    align-items: center;
    background: #f4f4f4;
    display: flex;
    height: 100%;
    justify-content: center;
    padding: 18%;
    width: 100%;
}

.story-hippo-image-fallback img {
    height: auto;
    max-width: 100%;
}

.story-hippo-empty-state {
    border-bottom: 1px solid var(--story-rule);
    padding: 100px 20px;
    text-align: center;
}

.story-hippo-empty-state h1 {
    font-size: clamp(48px, 8vw, 96px);
    margin: 0;
}

@media screen and (max-width: 1100px) {
    .story-hippo-home {
        padding-left: 28px;
        padding-right: 28px;
    }

    .story-hippo-hero-grid {
        grid-template-columns: minmax(180px, 0.7fr) minmax(0, 1.5fr);
    }

    .story-hippo-hero-right {
        display: grid;
        gap: 0 28px;
        grid-column: 1 / -1;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        margin-top: 16px;
    }

    .story-hippo-rail-heading {
        grid-column: 1 / -1;
    }
}

@media screen and (max-width: 767px) {
    .site-header.horizontal-style .site-branding-inner,
    .site-header.horizontal-style .menu-toggle {
        height: 64px;
        line-height: 64px;
    }

    .story-hippo-home {
        padding: 24px 16px 64px;
    }

    .story-hippo-hero {
        padding-bottom: 46px;
    }

    .story-hippo-hero-grid {
        display: flex;
        flex-direction: column;
        gap: 0;
    }

    .story-hippo-lead {
        order: 1;
    }

    .story-hippo-hero-left {
        gap: 36px;
        order: 2;
        padding-top: 48px;
    }

    .story-hippo-hero-right {
        display: block;
        margin-top: 54px;
        order: 3;
        width: 100%;
    }

    .story-hippo-lead .story-hippo-image-link {
        aspect-ratio: 4 / 5;
    }

    .story-hippo-lead-copy {
        padding: 17px 8px 0;
    }

    .story-hippo-lead-title {
        font-size: clamp(38px, 12vw, 54px);
    }

    .story-hippo-lead-excerpt {
        display: none;
    }

    .story-hippo-lead .story-hippo-byline {
        margin-top: 16px;
    }

    .story-hippo-side-title {
        font-size: 22px;
    }

    .story-hippo-rail-card {
        grid-template-columns: minmax(0, 1fr) 96px;
    }

    .story-hippo-rail-card h3 {
        font-size: 16px;
    }

    .story-hippo-section {
        padding-top: 56px;
    }

    .story-hippo-section-header {
        margin-bottom: 24px;
        padding: 16px 0 18px;
    }

    .story-hippo-section-header h2 {
        font-size: 45px;
    }

    .story-hippo-latest-grid,
    .story-hippo-more-grid {
        grid-template-columns: 1fr;
    }

    .story-hippo-latest-grid {
        gap: 42px;
    }

    .story-hippo-latest-card .story-hippo-card-copy {
        padding-left: 6px;
        padding-right: 6px;
    }

    .story-hippo-latest-card h3 {
        font-size: 24px;
    }

    .story-hippo-more-card,
    .story-hippo-more-card:nth-child(2) {
        border-top: 0;
        gap: 16px;
        grid-template-columns: 120px minmax(0, 1fr);
    }

    .story-hippo-more-card:first-child {
        border-top: 1px solid var(--story-rule);
    }

    .story-hippo-more-card h3 {
        font-size: 17px;
    }
}

@media screen and (max-width: 390px) {
    .story-hippo-default-logo img {
        max-width: 190px;
    }

    .story-hippo-more-card {
        grid-template-columns: 105px minmax(0, 1fr);
    }
}
