/* ==================== MOBILE-FIRST RESPONSIVE DESIGN ==================== */
/* Daily Record News - Mobile App Style */

/* Mobile Logo - Icon Only (Tide.co Style) */
@media (max-width: 768px) {
    .logo-circle {
        width: 40px !important;
        height: 40px !important;
    }
    
    .logo-drn {
        font-size: 0.95rem !important;
    }
    
    .logo h1,
    .logo-text {
        display: none !important; /* Hide text on mobile */
    }
    
    .logo .tagline {
        display: none !important; /* Hide tagline on mobile */
    }
    
    /* Remove DRN text badge - only show logo icon */
    .logo::after {
        display: none !important;
    }
    
    /* Remove hamburger menu - not needed */
    #navToggle {
        display: none !important;
    }
    
    /* Mobile navigation - vertical column */
    .main-nav {
        position: sticky;
        top: 70px;
        z-index: 100;
        background: white;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    }
    
    .nav-menu {
        display: flex;
        flex-direction: column !important;
        gap: 0 !important;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }
    
    .nav-menu.active {
        max-height: 600px !important;
    }
    
    .nav-menu li {
        width: 100%;
        border-bottom: 1px solid #e5e7eb;
    }
    
    .nav-menu li a {
        display: block;
        padding: 1rem 1.5rem;
        text-align: left;
        font-size: 1rem;
    }
    
    /* Mobile menu toggle button */
    .mobile-menu-toggle {
        display: block;
        width: 100%;
        padding: 1rem;
        background: var(--accent-blue);
        color: white;
        border: none;
        font-size: 1rem;
        font-weight: 600;
        cursor: pointer;
        text-align: left;
        position: relative;
    }
    
    .mobile-menu-toggle::after {
        content: '▼';
        position: absolute;
        right: 1rem;
        transition: transform 0.3s;
    }
    
    .mobile-menu-toggle.active::after {
        transform: rotate(180deg);
    }
}

/* Sticky header on scroll */
.header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.header.scrolled {
    padding: 0.5rem 0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

/* Compact sections - shorter heights */
.hero-section {
    padding: 1.5rem 0 !important;
    min-height: auto !important;
}

.hero-content h2 {
    font-size: 1.8rem !important;
    margin-bottom: 0.5rem !important;
}

.hero-content p {
    font-size: 1rem !important;
    margin-bottom: 1rem !important;
}

/* News Grid - 1 COLUMN on mobile for better readability */
@media (max-width: 768px) {
    .news-grid {
        grid-template-columns: 1fr !important;
        gap: 1.5rem !important;
    }
    
    .news-card {
        height: auto !important;
        max-width: 100% !important;
    }
    
    .news-card img {
        height: 200px !important;
        width: 100% !important;
    }
    
    .news-card h3,
    .news-card h4 {
        font-size: 1.1rem !important;
        line-height: 1.4 !important;
    }
    
    .news-card p {
        font-size: 0.9rem !important;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
}

/* Sponsored content placement - every 6 news items */
.news-grid .news-card:nth-child(6n+6) {
    grid-column: 1 / -1;
}

/* Animated sponsor ads */
.sponsor-ad-banner {
    width: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 1.5rem;
    margin: 2rem 0;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
}

.sponsor-ad-scroll {
    display: flex;
    gap: 2rem;
    animation: scrollAds 30s linear infinite;
}

.sponsor-ad-item {
    min-width: 300px;
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

@keyframes scrollAds {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-100%);
    }
}

.sponsor-ad-scroll:hover {
    animation-play-state: paused;
}

/* Remove unnecessary sections on mobile */
@media (max-width: 768px) {
    .personalize-section {
        display: none !important; /* Remove duplicate personalize feed */
    }
    
    .cta-section {
        display: none !important; /* Remove partner with us section */
    }
}

/* Compact featured section */
.featured-section {
    padding: 1rem 0 !important;
}

.featured-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)) !important;
    gap: 1rem !important;
}

/* Mobile footer - compact */
@media (max-width: 768px) {
    .footer {
        padding: 1rem 0 !important;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .footer-section {
        margin-bottom: 1rem;
    }
    
    .about-section {
        display: none; /* Hide on mobile to save space */
    }
}

/* DRN Logo SVG */
.drn-logo {
    width: 50px;
    height: 50px;
}

@media (min-width: 769px) {
    .drn-logo {
        width: 60px;
        height: 60px;
    }
}

/* Mobile-friendly buttons */
@media (max-width: 768px) {
    .header-actions button {
        padding: 0.5rem;
        font-size: 1rem;
    }
    
    .submit-story-btn span {
        display: none;
    }
    
    .submit-story-btn i {
        margin: 0;
    }
}

/* Smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

/* Breaking news badge - more prominent on mobile */
@media (max-width: 768px) {
    .breaking-badge {
        font-size: 0.8rem !important;
        padding: 0.4rem 0.8rem !important;
    }
}

/* ==================== MOBILE MENU OVERLAY - TIDE.CO STYLE ==================== */
@media (max-width: 768px) {
    .mobile-menu-overlay {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: linear-gradient(135deg, #1e40af, #3b82f6);
        z-index: 10000;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease, visibility 0.3s ease;
        overflow-y: auto;
    }
    
    .mobile-menu-overlay.active {
        opacity: 1;
        visibility: visible;
    }
    
    .mobile-menu-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 1rem 1.5rem;
        background: rgba(0, 0, 0, 0.1);
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .mobile-menu-logo {
        display: flex;
        align-items: center;
        color: white;
    }
    
    .mobile-menu-close {
        background: transparent;
        border: none;
        color: white;
        font-size: 1.5rem;
        cursor: pointer;
        padding: 0.5rem;
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 50%;
        transition: background 0.2s ease;
    }
    
    .mobile-menu-close:hover {
        background: rgba(255, 255, 255, 0.1);
    }
    
    .mobile-menu-content {
        padding: 1.5rem;
    }
    
    .mobile-menu-search {
        display: flex;
        align-items: center;
        background: rgba(255, 255, 255, 0.15);
        border-radius: 25px;
        padding: 0.75rem 1.25rem;
        margin-bottom: 1.5rem;
        border: 1px solid rgba(255, 255, 255, 0.2);
    }
    
    .mobile-menu-search i {
        color: white;
        margin-right: 0.75rem;
        opacity: 0.8;
    }
    
    .mobile-menu-search input {
        background: transparent;
        border: none;
        outline: none;
        color: white;
        font-size: 1rem;
        flex: 1;
        font-family: inherit;
    }
    
    .mobile-menu-search input::placeholder {
        color: rgba(255, 255, 255, 0.6);
    }
    
    .mobile-menu-nav {
        display: flex;
        flex-direction: column;
        gap: 0;
        margin-bottom: 2rem;
    }
    
    .mobile-menu-item {
        display: flex;
        align-items: center;
        padding: 1rem 1.25rem;
        color: white;
        text-decoration: none;
        font-size: 1.05rem;
        font-weight: 500;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        transition: background 0.2s ease, padding-left 0.2s ease;
    }
    
    .mobile-menu-item:hover {
        background: rgba(255, 255, 255, 0.1);
        padding-left: 1.75rem;
    }
    
    .mobile-menu-item.active {
        background: rgba(255, 255, 255, 0.15);
        border-left: 4px solid white;
    }
    
    .mobile-menu-item i {
        margin-right: 1rem;
        font-size: 1.1rem;
        width: 24px;
        text-align: center;
    }
    
    .mobile-menu-actions {
        display: flex;
        flex-direction: column;
        gap: 0.75rem;
        padding-top: 1rem;
        border-top: 1px solid rgba(255, 255, 255, 0.2);
    }
    
    .mobile-menu-action-btn {
        display: flex;
        align-items: center;
        padding: 0.875rem 1.25rem;
        background: rgba(255, 255, 255, 0.2);
        color: white;
        border: 1px solid rgba(255, 255, 255, 0.3);
        border-radius: 8px;
        font-size: 1rem;
        font-weight: 600;
        cursor: pointer;
        transition: all 0.2s ease;
        font-family: inherit;
        width: 100%;
        justify-content: flex-start;
    }
    
    .mobile-menu-action-btn:hover {
        background: rgba(255, 255, 255, 0.3);
        transform: translateY(-2px);
    }
    
    .mobile-menu-action-btn i {
        margin-right: 0.75rem;
        font-size: 1.1rem;
    }
}
