{% load static %}
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>{% block title %}Weather Forecast Pro{% endblock %}</title>
    <meta name="description" content="{% if project_description %}{{ project_description }}{% else %}Premium weather forecasting with hourly and 7-day insights.{% endif %}">
    
    <!-- Google Fonts -->
    <link rel="preconnect" href="https://fonts.googleapis.com">
    <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
    <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Outfit:wght@400;600;700&display=swap" rel="stylesheet">
    
    <!-- Bootstrap 5 -->
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet">
    <link rel="stylesheet" href="{% static 'css/custom.css' %}?v={{ deployment_timestamp }}">
    
    {% block extra_css %}{% endblock %}
</head>
<body class="bg-light">
    <nav class="navbar navbar-expand-lg navbar-dark sticky-top" style="background: rgba(45, 52, 54, 0.95); backdrop-filter: blur(10px);">
        <div class="container">
            <a class="navbar-brand d-flex align-items-center" href="{% url 'index' %}">
                <span class="brand-icon me-2">☁️</span>
                <span class="fw-bold fs-4" style="font-family: 'Outfit', sans-serif;">Weather<span class="text-info">Pro</span></span>
            </a>
            <button class="navbar-toggler border-0" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav">
                <span class="navbar-toggler-icon"></span>
            </button>
            <div class="collapse navbar-collapse" id="navbarNav">
                <ul class="navbar-nav ms-auto align-items-center">
                    <li class="nav-item">
                        <a class="nav-link px-3" href="#">Forecast</a>
                    </li>
                    <li class="nav-item">
                        <a class="nav-link px-3" href="#">Maps</a>
                    </li>
                    <li class="nav-item">
                        <a class="nav-link px-3" href="#">Alerts</a>
                    </li>
                    {% if user.is_staff %}
                    <li class="nav-item">
                        <a class="btn btn-outline-info btn-sm ms-lg-3" href="/admin/">Admin</a>
                    </li>
                    {% endif %}
                </ul>
            </div>
        </div>
    </nav>

    <main>
        {% block content %}{% endblock %}
    </main>

    <footer class="py-5 mt-5 bg-dark text-white">
        <div class="container">
            <div class="row align-items-center">
                <div class="col-md-6 text-center text-md-start">
                    <p class="mb-0">&copy; 2026 Weather Forecast Pro. Precision in every cloud.</p>
                </div>
                <div class="col-md-6 text-center text-md-end mt-3 mt-md-0">
                    <a href="#" class="text-white-50 text-decoration-none me-3">Privacy</a>
                    <a href="#" class="text-white-50 text-decoration-none">Terms</a>
                </div>
            </div>
        </div>
    </footer>

    <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script>
    {% block extra_js %}{% endblock %}
</body>
</html>