/* 
 * PinSaves.com - Modern Ultra-Premium CSS Theme
 * Color Palette: Coral Crimson (#FF3366), Deep Slate Navy (#0F172A), Soft Rose (#FFF1F2)
 */

:root {
    --primary: #FF3366;
    --primary-hover: #E02452;
    --primary-light: #FFF1F2;
    --accent: #7C3AED;
    --bg-main: #FAFAFD;
    --bg-card: #FFFFFF;
    --text-heading: #0F172A;
    --text-body: #475569;
    --text-muted: #94A3B8;
    --border-color: #E2E8F0;
    --shadow-sm: 0 4px 12px rgba(15, 23, 42, 0.05);
    --shadow-lg: 0 20px 40px rgba(255, 51, 102, 0.12);
    --radius-lg: 20px;
    --radius-md: 12px;
    --radius-sm: 8px;
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Plus Jakarta Sans', sans-serif;
}

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

body {
    font-family: var(--font-body);
    background-color: var(--bg-main);
    color: var(--text-body);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header & Nav */
.header {
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    font-family: var(--font-heading);
    font-size: 26px;
    font-weight: 800;
    color: var(--text-heading);
}

.logo-highlight {
    color: var(--primary);
}

.nav {
    display: flex;
    align-items: center;
    gap: 24px;
}

.nav-link {
    text-decoration: none;
    color: var(--text-body);
    font-weight: 600;
    font-size: 15px;
    transition: color 0.2s ease;
}

.nav-link:hover, .nav-link.active {
    color: var(--primary);
}

/* Language Dropdown (Pill style matching reference screenshot) */
.lang-selector {
    position: relative;
}

.lang-btn {
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    padding: 6px 14px;
    border-radius: 30px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: var(--text-heading);
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.lang-btn:hover {
    border-color: var(--primary);
    background: #fff0f3;
}

.lang-btn-badge {
    font-weight: 800;
    font-size: 12px;
    color: #475569;
    text-transform: uppercase;
}

.lang-btn-code {
    font-weight: 700;
    font-size: 14px;
    color: var(--text-heading);
}

.chevron-icon {
    transition: transform 0.2s ease;
}

.lang-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: #ffffff;
    border: 1px solid #f1f5f9;
    border-radius: 16px;
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.12);
    width: 220px;
    display: none;
    flex-direction: column;
    padding: 6px;
    z-index: 200;
}

.lang-dropdown.show {
    display: flex;
}

.lang-option {
    padding: 10px 14px;
    border-radius: 10px;
    text-decoration: none;
    color: #334155;
    font-size: 15px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.15s ease;
    margin-bottom: 2px;
}

.lang-option-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.lang-badge {
    font-size: 11px;
    font-weight: 800;
    text-transform: lowercase;
    color: #64748b;
    width: 20px;
    text-align: center;
    font-family: inherit;
}

.lang-name {
    font-size: 15px;
    font-weight: 500;
}

.lang-option:hover {
    background: #f8fafc;
}

.lang-option.active {
    background: #fff0f3;
    color: var(--primary);
}

.lang-option.active .lang-badge {
    color: var(--primary);
    font-weight: 900;
}

.lang-option.active .lang-name {
    color: var(--primary);
    font-weight: 700;
}

/* RTL Support */
[dir="rtl"] .lang-dropdown {
    right: auto;
    left: 0;
}

/* Hero Section */
.hero {
    padding: 70px 0 50px;
    text-align: center;
    background: radial-gradient(circle at top center, rgba(255, 51, 102, 0.08) 0%, rgba(250, 250, 253, 0) 70%);
}

.hero-title {
    font-family: var(--font-heading);
    font-size: 48px;
    font-weight: 800;
    color: var(--text-heading);
    margin-bottom: 18px;
    line-height: 1.2;
    letter-spacing: -0.5px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.hero-subtitle {
    font-size: 19px;
    line-height: 1.6;
    color: var(--text-body);
    max-width: 720px;
    margin: 0 auto 40px;
    font-weight: 400;
}

/* Downloader Form Card */
.downloader-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 36px;
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.07);
    max-width: 820px;
    margin: 0 auto;
}

.downloader-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 18px;
    font-size: 20px;
}

[dir="rtl"] .input-icon {
    left: auto;
    right: 18px;
}

.url-input {
    width: 100%;
    padding: 16px 120px 16px 50px;
    font-size: 16px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    outline: none;
    font-family: var(--font-body);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

[dir="rtl"] .url-input {
    padding: 16px 50px 16px 120px;
}

.url-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(255, 51, 102, 0.15);
}

.btn-input-action {
    position: absolute;
    right: 12px;
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    color: var(--text-heading);
}

[dir="rtl"] .btn-input-action {
    right: auto;
    left: 12px;
}

.btn-submit {
    background: linear-gradient(135deg, var(--primary) 0%, #E02452 100%);
    color: #ffffff;
    border: none;
    padding: 16px 32px;
    font-size: 18px;
    font-weight: 700;
    font-family: var(--font-heading);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 8px 20px rgba(255, 51, 102, 0.3);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 26px rgba(255, 51, 102, 0.4);
}

/* Result Box */
.result-box {
    margin-top: 30px;
    padding-top: 24px;
    border-top: 1px solid var(--border-color);
    text-align: left;
}

[dir="rtl"] .result-box {
    text-align: right;
}

.result-title {
    font-family: var(--font-heading);
    font-size: 22px;
    color: var(--text-heading);
    margin-bottom: 20px;
}

.result-content {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 24px;
    align-items: start;
}



.media-preview {
    min-height: 240px;
    background: #f8fafc;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.media-preview img, .media-preview video {
    width: 100%;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    max-height: 400px;
    object-fit: cover;
}

.media-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-heading);
    margin-bottom: 16px;
}

.download-links-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.btn-dl {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 24px;
    background: var(--text-heading);
    color: #ffffff;
    text-decoration: none;
    font-weight: 700;
    font-size: 15px;
    border-radius: var(--radius-md);
    transition: background 0.2s ease;
}

.btn-dl:hover {
    background: var(--primary);
}

.btn-reset {
    margin-top: 16px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-weight: 600;
    cursor: pointer;
    font-size: 14px;
}

.btn-reset:hover {
    color: var(--primary);
}

/* Features Section */
.section {
    padding: 60px 0;
}

.section-title {
    text-align: center;
    font-family: var(--font-heading);
    font-size: 32px;
    font-weight: 800;
    color: var(--text-heading);
    margin-bottom: 40px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
}

.feature-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    padding: 28px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    text-align: center;
}

.feature-icon {
    font-size: 36px;
    margin-bottom: 14px;
}

.feature-card h3 {
    font-family: var(--font-heading);
    font-size: 18px;
    margin-bottom: 8px;
    color: var(--text-heading);
}

/* How to Section */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
}

.step-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    padding: 24px;
    border-radius: var(--radius-md);
}

.step-number {
    font-family: var(--font-heading);
    font-size: 14px;
    font-weight: 800;
    color: var(--primary);
    text-transform: uppercase;
    margin-bottom: 8px;
}

/* FAQ Accordion */
.faq-list {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.faq-item {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.faq-question {
    padding: 20px 24px;
    font-family: var(--font-heading);
    font-size: 17px;
    font-weight: 700;
    color: var(--text-heading);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.faq-answer {
    padding: 0 24px 20px;
    display: none;
    color: var(--text-body);
    font-size: 15px;
}

.faq-item.active .faq-answer {
    display: block;
}

/* Alerts */
.alert {
    padding: 14px 18px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    margin-top: 14px;
}

.alert-error {
    background: #FEF2F2;
    color: #991B1B;
    border: 1px solid #FCA5A5;
}

.hide {
    display: none !important;
}

/* Footer */
.footer {
    background: var(--text-heading);
    color: #94A3B8;
    padding: 60px 0 30px;
    margin-top: auto;
}

.footer-container {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 32px;
    margin-bottom: 40px;
}

.footer-about .logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 18px;
    font-size: 28px;
}

.footer-about .logo-svg {
    width: 34px;
    height: 34px;
}

.footer-about p {
    font-size: 14.5px;
    line-height: 1.75;
    color: #94A3B8;
    max-width: 360px;
}

.footer-col h4 {
    color: #ffffff;
    font-family: var(--font-heading);
    margin-bottom: 16px;
    font-size: 16px;
}

.footer-col ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-col a {
    color: #94A3B8;
    text-decoration: none;
    font-size: 14px;
}

.footer-col a:hover {
    color: var(--primary);
}

.footer-bottom {
    border-top: 1px solid #1E293B;
    padding-top: 24px;
    text-align: center;
    font-size: 13px;
}

.disclaimer-text {
    margin-top: 8px;
    font-size: 12px;
    opacity: 0.7;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.mobile-nav-toggle {
    display: none !important;
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    border-radius: var(--radius-sm);
    padding: 6px 10px;
    cursor: pointer;
    color: var(--text-heading);
    transition: all 0.2s ease;
}

.mobile-nav-toggle:hover {
    border-color: var(--primary);
    background: #fff0f3;
    color: var(--primary);
}

.mobile-nav-drawer {
    display: none !important;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
    padding: 16px 20px;
    flex-direction: column;
    gap: 8px;
    z-index: 150;
}

.mobile-nav-drawer.show {
    display: flex !important;
}

.mobile-nav-link {
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    text-decoration: none;
    color: var(--text-heading);
    font-weight: 600;
    font-size: 15px;
    transition: all 0.15s ease;
}

.mobile-nav-link:hover, .mobile-nav-link.active {
    background: #FFF1F2;
    color: var(--primary);
    font-weight: 700;
}

/* Responsive Media Queries */
@media (max-width: 992px) {
    .nav {
        display: none !important;
    }

    .mobile-nav-toggle {
        display: flex !important;
        align-items: center;
        justify-content: center;
    }

    .header-container {
        height: 70px;
    }
}

@media (max-width: 768px) {
    .hero {
        padding: 40px 16px 30px;
    }

    .hero-title {
        font-size: 28px;
        margin-bottom: 12px;
    }

    .hero-subtitle {
        font-size: 15px;
        margin-bottom: 24px;
    }

    .downloader-card {
        padding: 20px 16px;
    }

    .url-input {
        font-size: 14px;
        padding: 14px 90px 14px 42px;
    }

    [dir="rtl"] .url-input {
        padding: 14px 42px 14px 90px;
    }

    .btn-input-action {
        padding: 6px 10px;
        font-size: 12px;
    }

    .btn-submit {
        padding: 14px 20px;
        font-size: 16px;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .steps-grid {
        grid-template-columns: 1fr;
    }

    .footer-container {
        grid-template-columns: 1fr;
        gap: 24px;
    }
}