/**
 * Archive Guides - Majestic Conciergerie
 * FluentSnippets CSS
 */

:root {
    --mag-blue: #1E2364;
    --mag-gold: #E4B864;
    --mag-cream: #F4EFE6;
    --mag-white: #FFFFFF;
    --mag-gray: #6B7280;
    --mag-dark: #1a1a1a;
    --mag-light: #f8fafc;
    --mag-radius: 12px;
    --mag-radius-lg: 20px;
    --font-display: 'Fraunces', serif;
    --font-body: 'DM Sans', sans-serif;
}

/* === BASE === */
.mag-main {
    font-family: var(--font-body);
    color: var(--mag-dark);
    line-height: 1.6;
    background: var(--mag-light);
}

.mag-seo-h1 {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.mag-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* === HERO === */
.mag-hero {
    position: relative;
    padding: 140px 0 100px;
    overflow: hidden;
    min-height: 480px;
    display: flex;
    align-items: center;
}

.mag-hero__bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.mag-hero__gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--mag-blue) 0%, #151842 50%, #0f1130 100%);
}

.mag-hero__shapes {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.mag-hero__shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.4;
}

.mag-hero__shape--1 {
    width: 500px;
    height: 500px;
    background: linear-gradient(135deg, var(--mag-gold) 0%, rgba(228,184,100,0.3) 100%);
    top: -200px;
    right: -100px;
    animation: magFloat 20s ease-in-out infinite;
}

.mag-hero__shape--2 {
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, rgba(30,35,100,0.8) 0%, rgba(228,184,100,0.2) 100%);
    bottom: -100px;
    left: -50px;
    animation: magFloat 15s ease-in-out infinite reverse;
}

.mag-hero__shape--3 {
    width: 200px;
    height: 200px;
    background: var(--mag-gold);
    top: 50%;
    left: 60%;
    opacity: 0.15;
    animation: magFloat 25s ease-in-out infinite;
}

@keyframes magFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(30px, -30px) scale(1.1); }
}

.mag-hero .mag-container {
    position: relative;
    z-index: 1;
}

.mag-hero__content {
    max-width: 700px;
}

.mag-hero__label {
    display: inline-block;
    padding: 8px 16px;
    background: rgba(228,184,100,0.15);
    color: var(--mag-gold);
    font-size: 14px;
    font-weight: 600;
    border-radius: 99px;
    margin-bottom: 20px;
}

.mag-hero__title {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 600;
    color: white;
    line-height: 1.15;
    margin-bottom: 16px;
}

.mag-hero__subtitle {
    font-size: 1.15rem;
    color: rgba(255,255,255,0.8);
    margin-bottom: 32px;
    max-width: 550px;
}

.mag-hero__stats {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
}

.mag-hero__stat {
    text-align: left;
}

.mag-hero__stat-value {
    display: block;
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 600;
    color: var(--mag-gold);
}

.mag-hero__stat-label {
    font-size: 14px;
    color: rgba(255,255,255,0.7);
}

/* === FILTRES === */
.mag-filters {
    background: var(--mag-white);
    padding: 0;
    border-bottom: 1px solid rgba(30,35,100,0.06);
    position: sticky;
    top: 0;
    z-index: 100;
}

.mag-filters__bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 0;
    overflow-x: auto;
    scrollbar-width: none;
}

.mag-filters__bar::-webkit-scrollbar { display: none; }

.mag-filters__toggle {
    display: none;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: transparent;
    color: var(--mag-gray);
    border: 1px solid rgba(30,35,100,0.12);
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.mag-filters__toggle:hover {
    background: var(--mag-cream);
}

.mag-filters__toggle svg {
    width: 18px;
    height: 18px;
}

.mag-filters__count {
    background: var(--mag-gold);
    color: var(--mag-blue);
    width: 20px;
    height: 20px;
    border-radius: 50%;
    font-size: 11px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mag-filters__spacer {
    flex: 1;
}

.mag-filter-dropdown {
    position: relative;
}

.mag-filter-dropdown__btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    background: transparent;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: var(--mag-gray);
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.mag-filter-dropdown__btn:hover {
    background: rgba(30,35,100,0.04);
    color: var(--mag-blue);
}

.mag-filter-dropdown__btn.has-value {
    color: var(--mag-blue);
    background: rgba(228,184,100,0.12);
}

.mag-filter-dropdown__btn svg {
    width: 16px;
    height: 16px;
    opacity: 0.5;
}

.mag-filter-dropdown.open .mag-filter-dropdown__btn svg:last-child {
    transform: rotate(180deg);
}

.mag-filter-dropdown__menu {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    min-width: 240px;
    max-height: 360px;
    overflow-y: auto;
    background: var(--mag-white);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(30,35,100,0.15), 0 0 0 1px rgba(30,35,100,0.05);
    padding: 8px;
    display: none;
    z-index: 9999;
}

.mag-filter-dropdown.open .mag-filter-dropdown__menu {
    display: block;
}

.mag-filter-dropdown__menu--right {
    left: auto;
    right: 0;
}

.mag-filter-dropdown__item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 8px;
    color: var(--mag-dark);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.15s;
}

.mag-filter-dropdown__item:hover {
    background: var(--mag-cream);
}

.mag-filter-dropdown__item.selected {
    background: rgba(228,184,100,0.15);
    color: var(--mag-blue);
    font-weight: 500;
}

.mag-filter-dropdown__item svg {
    width: 18px;
    height: 18px;
    color: var(--mag-gold);
}

.mag-filter-dropdown__count {
    margin-left: auto;
    background: var(--mag-cream);
    padding: 2px 8px;
    border-radius: 99px;
    font-size: 12px;
    color: var(--mag-gray);
}

.mag-niveau-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

/* Chips */
.mag-filters__chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding-bottom: 14px;
}

.mag-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: var(--mag-blue);
    color: white;
    font-size: 13px;
    font-weight: 500;
    border-radius: 99px;
    text-decoration: none;
    transition: all 0.2s;
}

.mag-chip svg {
    width: 14px;
    height: 14px;
}

.mag-chip:hover {
    background: #2a3178;
}

.mag-chip--reset {
    background: transparent;
    color: var(--mag-gray);
    border: 1px dashed rgba(30,35,100,0.2);
}

.mag-chip--reset:hover {
    background: var(--mag-cream);
    color: var(--mag-blue);
    border-color: transparent;
}

/* === DRAWER MOBILE === */
.mag-drawer {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
}

.mag-drawer.open {
    display: block;
}

.mag-drawer__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.5);
    animation: magFadeIn 0.2s ease-out;
}

.mag-drawer__content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--mag-white);
    border-radius: 20px 20px 0 0;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    animation: magSlideUp 0.3s ease-out;
}

@keyframes magFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes magSlideUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

.mag-drawer__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid rgba(30,35,100,0.08);
}

.mag-drawer__title {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--mag-blue);
}

.mag-drawer__close {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--mag-cream);
    border: none;
    border-radius: 50%;
    cursor: pointer;
}

.mag-drawer__close svg {
    width: 20px;
    height: 20px;
    color: var(--mag-gray);
}

.mag-drawer__body {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
}

.mag-drawer__section {
    margin-bottom: 28px;
}

.mag-drawer__section-title {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--mag-gray);
    margin-bottom: 12px;
}

.mag-drawer__option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--mag-light);
    border-radius: 10px;
    margin-bottom: 8px;
    color: var(--mag-dark);
    text-decoration: none;
    font-size: 15px;
    transition: all 0.2s;
}

.mag-drawer__option.selected {
    background: rgba(228,184,100,0.15);
    color: var(--mag-blue);
    font-weight: 500;
}

.mag-drawer__option svg {
    width: 20px;
    height: 20px;
    color: var(--mag-gold);
}

.mag-drawer__check {
    margin-left: auto;
    color: var(--mag-gold);
    font-weight: 600;
}

.mag-drawer__footer {
    padding: 20px 24px;
    border-top: 1px solid rgba(30,35,100,0.08);
}

.mag-drawer__reset {
    display: block;
    width: 100%;
    padding: 14px;
    background: var(--mag-cream);
    color: var(--mag-blue);
    font-weight: 600;
    font-size: 15px;
    text-align: center;
    text-decoration: none;
    border-radius: 10px;
}

/* === INTRO === */
.mag-intro {
    padding: 80px 0;
    background: var(--mag-white);
}

.mag-intro__grid {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 60px;
    align-items: center;
}

.mag-intro__title {
    font-family: var(--font-display);
    font-size: 2rem;
    color: var(--mag-blue);
    margin-bottom: 20px;
}

.mag-intro__text {
    font-size: 1.1rem;
    color: var(--mag-gray);
    margin-bottom: 28px;
    line-height: 1.7;
}

.mag-intro__list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mag-intro__list li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid rgba(30,35,100,0.06);
    font-size: 15px;
}

.mag-intro__list li:last-child {
    border-bottom: none;
}

.mag-intro__list svg {
    width: 20px;
    height: 20px;
    color: var(--mag-gold);
    flex-shrink: 0;
    margin-top: 2px;
}

.mag-intro__visual {
    display: flex;
    justify-content: center;
}

.mag-intro__card {
    background: linear-gradient(135deg, var(--mag-blue) 0%, #2a3178 100%);
    color: white;
    padding: 48px;
    border-radius: var(--mag-radius-lg);
    text-align: center;
    box-shadow: 0 20px 40px rgba(30,35,100,0.2);
}

.mag-intro__card-icon {
    font-size: 3rem;
    margin-bottom: 16px;
}

.mag-intro__card-stat {
    font-family: var(--font-display);
    font-size: 3.5rem;
    font-weight: 600;
    color: var(--mag-gold);
}

.mag-intro__card-label {
    font-size: 14px;
    opacity: 0.8;
}

/* === THÉMATIQUES === */
.mag-themes {
    padding: 60px 0 80px;
}

.mag-themes__title {
    font-family: var(--font-display);
    font-size: 1.75rem;
    color: var(--mag-blue);
    margin-bottom: 32px;
}

.mag-themes__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
}

.mag-theme-card {
    background: var(--mag-white);
    padding: 24px;
    border-radius: var(--mag-radius);
    text-decoration: none;
    text-align: center;
    transition: all 0.3s;
    border: 1px solid rgba(30,35,100,0.06);
}

.mag-theme-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(30,35,100,0.1);
    border-color: var(--mag-gold);
}

.mag-theme-card__icon {
    width: 48px;
    height: 48px;
    background: var(--mag-cream);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.mag-theme-card__icon svg {
    width: 24px;
    height: 24px;
    color: var(--mag-gold);
}

.mag-theme-card__title {
    font-family: var(--font-display);
    font-size: 1rem;
    color: var(--mag-blue);
    margin-bottom: 4px;
}

.mag-theme-card__count {
    font-size: 13px;
    color: var(--mag-gray);
}

/* === GUIDES GRID === */
.mag-guides {
    padding: 60px 0 80px;
}

.mag-guides__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 32px;
}

.mag-guides__title {
    font-family: var(--font-display);
    font-size: 1.75rem;
    color: var(--mag-blue);
}

.mag-guides__count {
    font-size: 14px;
    color: var(--mag-gray);
    background: var(--mag-white);
    padding: 6px 14px;
    border-radius: 99px;
}

.mag-guides__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 28px;
}

/* Guide Card */
.mag-guide-card {
    background: var(--mag-white);
    border-radius: var(--mag-radius-lg);
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.mag-guide-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(30,35,100,0.12);
}

.mag-guide-card__img {
    height: 180px;
    background: var(--mag-cream);
    background-size: cover;
    background-position: center;
    position: relative;
}

.mag-guide-card__placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mag-guide-card__placeholder svg {
    width: 48px;
    height: 48px;
    color: var(--mag-gold);
    opacity: 0.5;
}

.mag-guide-card__badge {
    position: absolute;
    top: 16px;
    right: 16px;
    padding: 6px 12px;
    background: color-mix(in srgb, var(--niveau-color) 90%, black);
    color: white;
    font-size: 12px;
    font-weight: 600;
    border-radius: 99px;
}

.mag-guide-card__content {
    padding: 24px;
}

.mag-guide-card__theme {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--mag-gold);
    margin-bottom: 12px;
}

.mag-guide-card__theme svg {
    width: 14px;
    height: 14px;
}

.mag-guide-card__title {
    font-family: var(--font-display);
    font-size: 1.2rem;
    color: var(--mag-blue);
    margin-bottom: 10px;
    line-height: 1.35;
}

.mag-guide-card__excerpt {
    font-size: 14px;
    color: var(--mag-gray);
    line-height: 1.6;
    margin-bottom: 16px;
}

.mag-guide-card__meta {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 13px;
    color: var(--mag-gray);
}

.mag-guide-card__meta::before {
    content: '';
    position: absolute;
    left: 24px;
    right: 24px;
    height: 1px;
    background: rgba(30,35,100,0.06);
    margin-top: -16px;
}

.mag-guide-card__reading::before {
    content: '•';
    margin-right: 16px;
    opacity: 0.4;
}

/* Empty state */
.mag-guides__empty {
    text-align: center;
    padding: 80px 40px;
    background: var(--mag-white);
    border-radius: var(--mag-radius-lg);
}

.mag-guides__empty-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.mag-guides__empty h3 {
    font-family: var(--font-display);
    font-size: 1.5rem;
    color: var(--mag-blue);
    margin-bottom: 12px;
}

.mag-guides__empty p {
    color: var(--mag-gray);
    margin-bottom: 24px;
}

.mag-guides__empty-btn {
    display: inline-block;
    padding: 14px 28px;
    background: var(--mag-blue);
    color: white;
    font-weight: 600;
    border-radius: 99px;
    text-decoration: none;
}

/* === TÉMOIGNAGE === */
.mag-testimonial {
    padding: 80px 0;
    background: var(--mag-white);
}

.mag-testimonial__card {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    padding: 60px;
    background: linear-gradient(135deg, var(--mag-cream) 0%, #f5f0e7 100%);
    border-radius: var(--mag-radius-lg);
    position: relative;
}

.mag-testimonial__quote {
    font-family: var(--font-display);
    font-size: 6rem;
    color: var(--mag-gold);
    opacity: 0.3;
    position: absolute;
    top: 20px;
    left: 40px;
    line-height: 1;
}

.mag-testimonial__text {
    font-family: var(--font-display);
    font-size: 1.5rem;
    color: var(--mag-blue);
    line-height: 1.5;
    margin-bottom: 24px;
    position: relative;
}

.mag-testimonial__author {
    font-style: normal;
    color: var(--mag-gray);
    font-size: 15px;
}

/* === FAQ === */
.mag-faq {
    padding: 80px 0;
}

.mag-faq__title {
    font-family: var(--font-display);
    font-size: 1.75rem;
    color: var(--mag-blue);
    margin-bottom: 40px;
    text-align: center;
}

.mag-faq__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    max-width: 1000px;
    margin: 0 auto;
}

.mag-faq__item {
    background: var(--mag-white);
    padding: 28px;
    border-radius: var(--mag-radius);
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.mag-faq__question {
    font-family: var(--font-display);
    font-size: 1.1rem;
    color: var(--mag-blue);
    margin-bottom: 12px;
}

.mag-faq__answer {
    font-size: 15px;
    color: var(--mag-gray);
    line-height: 1.7;
}

/* === CTA === */
.mag-cta {
    padding: 100px 0;
    background: linear-gradient(135deg, var(--mag-blue) 0%, #151842 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.mag-cta::before {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(228,184,100,0.12) 0%, transparent 70%);
    top: -200px;
    right: -100px;
}

.mag-cta__content {
    position: relative;
    z-index: 1;
}

.mag-cta__title {
    font-family: var(--font-display);
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    color: white;
    margin-bottom: 16px;
}

.mag-cta__text {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.8);
    margin-bottom: 32px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.mag-cta__btn {
    display: inline-block;
    padding: 18px 40px;
    background: var(--mag-gold);
    color: var(--mag-blue);
    font-weight: 600;
    font-size: 1rem;
    border-radius: 99px;
    text-decoration: none;
    transition: all 0.3s;
}

.mag-cta__btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(228,184,100,0.4);
}

/* === RESPONSIVE === */
@media (max-width: 1024px) {
    .mag-intro__grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .mag-intro__visual {
        order: -1;
    }
    
    .mag-guides__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .mag-hero {
        padding: 100px 0 70px;
        min-height: auto;
    }
    
    .mag-filters__toggle {
        display: flex;
    }
    
    .mag-filter-dropdown,
    .mag-filters__spacer {
        display: none;
    }
    
    .mag-themes__grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .mag-guides__grid {
        grid-template-columns: 1fr;
    }
    
    .mag-faq__grid {
        grid-template-columns: 1fr;
    }
    
    .mag-testimonial__card {
        padding: 40px 24px;
    }
    
    .mag-testimonial__text {
        font-size: 1.25rem;
    }
}

@media (max-width: 480px) {
    .mag-container {
        padding: 0 16px;
    }
    
    .mag-intro__card {
        padding: 32px 24px;
    }
    
    .mag-themes__grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }
    
    .mag-theme-card {
        padding: 20px 16px;
    }
}

/* === ANIMATIONS === */
@media (prefers-reduced-motion: no-preference) {
    .mag-guide-card {
        animation: magCardFadeIn 0.5s ease-out backwards;
    }
    
    .mag-guides__grid .mag-guide-card:nth-child(1) { animation-delay: 0.05s; }
    .mag-guides__grid .mag-guide-card:nth-child(2) { animation-delay: 0.1s; }
    .mag-guides__grid .mag-guide-card:nth-child(3) { animation-delay: 0.15s; }
    .mag-guides__grid .mag-guide-card:nth-child(4) { animation-delay: 0.2s; }
    .mag-guides__grid .mag-guide-card:nth-child(5) { animation-delay: 0.25s; }
    .mag-guides__grid .mag-guide-card:nth-child(6) { animation-delay: 0.3s; }
    
    @keyframes magCardFadeIn {
        from {
            opacity: 0;
            transform: translateY(20px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}