/* ============================================================
   AYAK Premium Footer — footer.css
   ============================================================ */

/* ── Variables ───────────────────────────────────────────── */
:root {
    --footer-bg: #0f1b2d;
    --footer-bg-secondary: #162236;
    --footer-border: rgba(255, 255, 255, 0.08);
    --footer-text: rgba(255, 255, 255, 0.65);
    --footer-text-hover: #ffffff;
    --footer-heading: #ffffff;
    --footer-accent: #3b82f6;
    --footer-accent-glow: rgba(59, 130, 246, 0.25);
    --footer-radius: 20px;
    --footer-transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Main Container ──────────────────────────────────────── */
.ayak-footer {
    background: var(--footer-bg);
    color: var(--footer-text);
    border-radius: var(--footer-radius);
    margin: 2.5rem 1rem 1rem;
    padding: 0;
    overflow: hidden;
    box-shadow:
        0 -4px 30px rgba(0, 0, 0, 0.15),
        0 0 60px rgba(15, 27, 45, 0.3);
    position: relative;
}

.ayak-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--footer-accent), transparent);
    opacity: 0.5;
}

/* ── Newsletter Band ─────────────────────────────────────── */
.footer-newsletter {
    background: linear-gradient(135deg, var(--footer-bg-secondary) 0%, #1a2d4a 100%);
    padding: 2.5rem 2rem;
    text-align: center;
    border-bottom: 1px solid var(--footer-border);
    position: relative;
}

.footer-newsletter h4 {
    color: var(--footer-heading);
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.footer-newsletter p {
    color: var(--footer-text);
    font-size: 0.9rem;
    margin-bottom: 1.25rem;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.newsletter-form {
    display: flex;
    max-width: 480px;
    margin: 0 auto;
    gap: 0.5rem;
}

.newsletter-form .form-control {
    flex: 1;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--footer-border);
    border-radius: 12px;
    color: #fff;
    padding: 0.75rem 1.25rem;
    font-size: 0.9rem;
    transition: var(--footer-transition);
}

.newsletter-form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.newsletter-form .form-control:focus {
    outline: none;
    border-color: var(--footer-accent);
    box-shadow: 0 0 0 3px var(--footer-accent-glow);
    background: rgba(255, 255, 255, 0.1);
}

.newsletter-btn {
    background: linear-gradient(135deg, var(--footer-accent), #2563eb);
    border: none;
    border-radius: 12px;
    color: #fff;
    padding: 0.75rem 1.75rem;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--footer-transition);
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.newsletter-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px var(--footer-accent-glow);
}

.newsletter-btn:active {
    transform: translateY(0);
}

.newsletter-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.newsletter-message {
    margin-top: 0.75rem;
    font-size: 0.85rem;
    min-height: 1.25rem;
    transition: var(--footer-transition);
}

.newsletter-message.success {
    color: #4ade80;
}

.newsletter-message.error {
    color: #f87171;
}

/* ── Main Content Grid ───────────────────────────────────── */
.footer-content {
    padding: 3rem 2rem 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
    gap: 2.5rem;
}

/* ── Brand Column ────────────────────────────────────────── */
.footer-brand {
    padding-left: 1rem;
}

.footer-brand-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    text-decoration: none;
}

.footer-brand-logo img {
    height: 48px;
    width: auto;
    filter: brightness(1.1);
}

.footer-brand-logo .brand-name {
    color: var(--footer-heading);
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.footer-brand-tagline {
    color: var(--footer-accent);
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 1rem;
    display: block;
}

.footer-brand-desc {
    color: var(--footer-text);
    font-size: 0.875rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

/* ── Social Links ────────────────────────────────────────── */
.footer-social {
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.footer-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--footer-border);
    color: var(--footer-text);
    font-size: 1.1rem;
    text-decoration: none;
    transition: var(--footer-transition);
}

.footer-social a:hover {
    background: var(--footer-accent);
    border-color: var(--footer-accent);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px var(--footer-accent-glow);
}

.footer-social a.instagram:hover { background: linear-gradient(135deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); border-color: transparent; }
.footer-social a.telegram:hover { background: #0088cc; border-color: transparent; }
.footer-social a.whatsapp:hover { background: #25d366; border-color: transparent; }
.footer-social a.linkedin:hover { background: #0077b5; border-color: transparent; }
.footer-social a.youtube:hover { background: #ff0000; border-color: transparent; }
.footer-social a.github:hover { background: #333; border-color: transparent; }
.footer-social a.facebook:hover { background: #1877f2; border-color: transparent; }
.footer-social a.x:hover { background: #000; border-color: transparent; }

/* ── Link Columns ────────────────────────────────────────── */
.footer-links h5 {
    color: var(--footer-heading);
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 1.25rem;
    position: relative;
    padding-bottom: 0.75rem;
}

.footer-links h5::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 30px;
    height: 2px;
    background: var(--footer-accent);
    border-radius: 2px;
}

.footer-links ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links ul li {
    margin-bottom: 0.6rem;
}

.footer-links ul li a {
    color: var(--footer-text);
    text-decoration: none;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.3rem 0;
    transition: var(--footer-transition);
}

.footer-links ul li a i {
    font-size: 0.8rem;
    opacity: 0;
    transform: translateX(5px);
    transition: var(--footer-transition);
}

.footer-links ul li a:hover {
    color: var(--footer-text-hover);
    padding-right: 0.25rem;
}

.footer-links ul li a:hover i {
    opacity: 1;
    transform: translateX(0);
}

/* ── Contact Info ────────────────────────────────────────── */
.footer-contact-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

.footer-contact-item i {
    color: var(--footer-accent);
    font-size: 1rem;
    margin-top: 0.15rem;
    flex-shrink: 0;
}

.footer-contact-item a {
    color: var(--footer-text);
    text-decoration: none;
    transition: var(--footer-transition);
}

.footer-contact-item a:hover {
    color: var(--footer-text-hover);
}

.footer-contact-item p {
    margin: 0;
    line-height: 1.6;
}

/* ── Bottom Bar ──────────────────────────────────────────── */
.footer-bottom {
    border-top: 1px solid var(--footer-border);
    padding: 1.25rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-copyright {
    font-size: 0.8rem;
    color: var(--footer-text);
    opacity: 0.7;
}

.footer-bottom-links {
    display: flex;
    gap: 1.5rem;
}

.footer-bottom-links a {
    color: var(--footer-text);
    text-decoration: none;
    font-size: 0.8rem;
    opacity: 0.7;
    transition: var(--footer-transition);
}

.footer-bottom-links a:hover {
    color: var(--footer-text-hover);
    opacity: 1;
}

/* ── Scroll to Top ───────────────────────────────────────── */
.footer-scroll-top {
    position: fixed;
    bottom: 2rem;
    left: 2rem;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--footer-accent);
    color: #fff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--footer-transition);
    box-shadow: 0 4px 15px var(--footer-accent-glow);
    z-index: 1000;
}

.footer-scroll-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.footer-scroll-top:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--footer-accent-glow);
}

/* ── Animations ──────────────────────────────────────────── */
.footer-fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.footer-fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 1200px) {
    .footer-grid {
        grid-template-columns: 1.2fr 1fr 1fr;
    }
    .footer-brand {
        grid-column: 1 / -1;
        padding-left: 0;
        padding-bottom: 1rem;
        border-bottom: 1px solid var(--footer-border);
        margin-bottom: 0.5rem;
    }
}

@media (max-width: 992px) {
    .ayak-footer {
        margin: 2rem 0.75rem 0.75rem;
        border-radius: 16px;
    }
    .footer-content {
        padding: 2rem 1.5rem 1.5rem;
    }
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
    .footer-brand {
        grid-column: 1 / -1;
    }
}

@media (max-width: 768px) {
    .ayak-footer {
        margin: 1.5rem 0.5rem 0.5rem;
        border-radius: 14px;
    }
    .footer-newsletter {
        padding: 2rem 1.25rem;
    }
    .newsletter-form {
        flex-direction: column;
    }
    .newsletter-btn {
        justify-content: center;
    }
    .footer-content {
        padding: 1.5rem 1.25rem 1rem;
    }
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 1.75rem;
    }
    .footer-bottom {
        flex-direction: column;
        text-align: center;
        padding: 1rem 1.25rem;
    }
    .footer-bottom-links {
        justify-content: center;
    }
}

@media (max-width: 576px) {
    .ayak-footer {
        margin: 1rem 0.5rem 0.5rem;
        border-radius: 12px;
    }
    .footer-newsletter h4 {
        font-size: 1.1rem;
    }
    .footer-social a {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }
}

/* ── RTL specific overrides ──────────────────────────────── */
[dir="rtl"] .footer-links h5::after {
    right: auto;
    left: 0;
}

[dir="rtl"] .footer-links ul li a:hover {
    padding-right: 0;
    padding-left: 0.25rem;
}

[dir="rtl"] .footer-links ul li a i {
    transform: translateX(-5px);
}

[dir="rtl"] .footer-links ul li a:hover i {
    transform: translateX(0);
}

[dir="rtl"] .footer-scroll-top {
    left: auto;
    right: 2rem;
}
