/* HalalDetect - Shared Components */

/* ====================
   Header & Navigation
   ==================== */
.header {
    background-color: white;
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: box-shadow var(--transition-normal);
}

.header.scrolled {
    box-shadow: var(--shadow-lg);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem var(--spacing-md);
    max-width: 1400px;
    margin: 0 auto;
}

/* Logo */
.logo {
    font-family: 'Poppins', sans-serif;
    font-size: 24px;
    text-decoration: none;
    color: var(--primary-teal);
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo-text-bold {
    font-weight: 700;
}

.logo-text-regular {
    font-weight: 400;
}

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

/* Desktop Navigation */
.nav-desktop {
    display: none;
    align-items: center;
    gap: var(--spacing-lg);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: var(--spacing-lg);
    list-style: none;
}

.nav-links > li {
    position: relative;
}

.nav-links > li > a {
    font-weight: 500;
    color: var(--text-primary);
    padding: 0.5rem 0;
    transition: color var(--transition-fast);
}

.nav-links > li > a:hover {
    color: var(--primary-teal);
}

/* Dropdown Menu */
.dropdown {
    position: relative;
}

.dropdown-toggle {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.dropdown-toggle::after {
    content: '▼';
    font-size: 10px;
    transition: transform var(--transition-fast);
}

.dropdown:hover .dropdown-toggle::after {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: white;
    box-shadow: var(--shadow-lg);
    border-radius: var(--radius-sm);
    min-width: 240px;
    padding: var(--spacing-sm) 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all var(--transition-normal);
    z-index: 1001;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    list-style: none;
}

.dropdown-menu a {
    display: block;
    padding: 0.75rem 1.5rem;
    color: var(--text-primary);
    font-size: var(--small-text);
    transition: background-color var(--transition-fast);
}

.dropdown-menu a:hover {
    background-color: var(--bg-teal-light);
    color: var(--primary-teal);
}

/* Mobile Navigation */
.nav-mobile {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.hamburger {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--primary-teal);
    cursor: pointer;
    padding: 0.5rem;
}

.search-icon {
    background: none;
    border: none;
    font-size: 20px;
    color: var(--primary-teal);
    cursor: pointer;
    padding: 0.5rem;
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 0;
    left: -100%;
    width: 80%;
    max-width: 320px;
    height: 100vh;
    background-color: white;
    box-shadow: var(--shadow-lg);
    transition: left var(--transition-normal);
    z-index: 2000;
    overflow-y: auto;
}

.mobile-menu.active {
    left: 0;
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-md);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.mobile-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--text-primary);
    cursor: pointer;
}

.mobile-menu-content {
    padding: var(--spacing-md);
}

.mobile-menu-content ul {
    list-style: none;
}

.mobile-menu-content > ul > li {
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.mobile-menu-content a {
    display: block;
    padding: 0.75rem 0;
    color: var(--text-primary);
    font-weight: 500;
}

.mobile-dropdown-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 0.75rem 0;
    background: none;
    border: none;
    font-family: 'Inter', sans-serif;
    font-size: var(--body-text);
    font-weight: 500;
    color: var(--text-primary);
    cursor: pointer;
    text-align: left;
}

.mobile-dropdown-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height var(--transition-normal);
    padding-left: var(--spacing-md);
}

.mobile-dropdown-content.active {
    max-height: 500px;
}

.mobile-dropdown-content a {
    font-size: var(--small-text);
    font-weight: 400;
    padding: 0.5rem 0;
    color: var(--text-secondary);
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
    z-index: 1999;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

@media (min-width: 1024px) {
    .nav-desktop {
        display: flex;
    }

    .nav-mobile {
        display: none;
    }

    .header-content {
        padding: 1rem var(--spacing-lg);
    }
}

/* ====================
   Footer
   ==================== */
.footer {
    background-color: var(--soft-brown);
    color: var(--cream-bg);
    padding: var(--spacing-2xl) 0 var(--spacing-md);
}

.footer a {
    color: var(--cream-bg);
    opacity: 0.9;
    font-size: var(--small-text);
}

.footer a:hover {
    opacity: 1;
    color: white;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-xl);
}

@media (min-width: 768px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .footer-content {
        grid-template-columns: repeat(4, 1fr);
    }
}

.footer-column h4 {
    color: white;
    font-size: var(--body-text-large);
    margin-bottom: var(--spacing-md);
}

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

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

.footer-brand {
    margin-bottom: var(--spacing-md);
}

.footer-tagline {
    font-size: var(--small-text);
    line-height: var(--line-height-relaxed);
    opacity: 0.9;
    margin-bottom: var(--spacing-md);
}

.social-links {
    display: flex;
    gap: var(--spacing-sm);
}

.social-links a {
    display: inline-block;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: all var(--transition-fast);
}

.social-links a:hover {
    background-color: var(--primary-teal);
    transform: translateY(-2px);
}

.footer-newsletter {
    background-color: rgba(255, 255, 255, 0.05);
    padding: var(--spacing-lg);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-lg);
}

.footer-newsletter h4 {
    font-size: var(--body-text-large);
    margin-bottom: var(--spacing-sm);
}

.newsletter-form {
    display: flex;
    gap: var(--spacing-sm);
    flex-direction: column;
}

@media (min-width: 768px) {
    .newsletter-form {
        flex-direction: row;
    }
}

.newsletter-form input {
    flex: 1;
    padding: 0.75rem;
    border: none;
    border-radius: var(--radius-sm);
    font-size: var(--small-text);
}

.newsletter-form button {
    white-space: nowrap;
}

.footer-bottom {
    text-align: center;
    padding-top: var(--spacing-lg);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: var(--small-text);
    opacity: 0.8;
}

/* ====================
   Article Card
   ==================== */
.article-card {
    background-color: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    transition: all var(--transition-normal);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.article-card:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-4px);
}

.article-image {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
    background-color: var(--warm-gray);
}

.article-content {
    padding: var(--spacing-md);
    flex: 1;
    display: flex;
    flex-direction: column;
}

.article-category {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background-color: var(--bg-teal-light);
    color: var(--primary-teal);
    border-radius: var(--radius-sm);
    font-size: var(--small-text);
    font-weight: 500;
    margin-bottom: var(--spacing-sm);
    width: fit-content;
}

.article-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    color: var(--text-primary);
    line-height: var(--line-height-tight);
}

.article-excerpt {
    font-size: var(--small-text);
    color: var(--text-secondary);
    line-height: var(--line-height-normal);
    margin-bottom: var(--spacing-md);
    flex: 1;
}

.article-meta {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-size: var(--small-text);
    color: var(--text-secondary);
    padding-top: var(--spacing-sm);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

/* ====================
   Category Card
   ==================== */
.category-card {
    background-color: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: var(--spacing-lg);
    text-align: center;
    transition: all var(--transition-normal);
    cursor: pointer;
    border: 2px solid transparent;
}

.category-card:hover {
    border-color: var(--primary-teal);
    box-shadow: var(--shadow-hover);
    transform: translateY(-4px);
}

.category-icon {
    width: 80px;
    height: 80px;
    background-color: var(--bg-teal-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    margin: 0 auto var(--spacing-md);
    transition: all var(--transition-normal);
    color: var(--primary-teal);
}

.category-card:hover .category-icon {
    background-color: var(--primary-teal);
    color: white;
}

.category-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    color: var(--text-primary);
}

.category-description {
    font-size: var(--small-text);
    color: var(--text-secondary);
    line-height: var(--line-height-normal);
}

/* ====================
   Section Headers
   ==================== */
.section-header {
    text-align: center;
    margin-bottom: var(--spacing-xl);
}

.section-header h2 {
    margin-bottom: var(--spacing-sm);
}

.section-header p {
    font-size: var(--body-text-large);
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto;
}

/* ====================
   Tags
   ==================== */
.tag {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background-color: rgba(0, 0, 0, 0.05);
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    font-size: var(--small-text);
    margin: 0.25rem;
}

.tag.tag-teal {
    background-color: var(--bg-teal-light);
    color: var(--primary-teal);
}

.tag.tag-orange {
    background-color: rgba(230, 129, 97, 0.1);
    color: var(--gentle-orange);
}

.tag.tag-green {
    background-color: rgba(139, 168, 136, 0.1);
    color: var(--sage-green);
}
