/*
Theme Name: Latheefiya School Theme
Theme URI: http://latheefiyaschool.edu.in
Author: Antigravity Expert Developer
Author URI: https://google.com
Description: A modern, premium, fully responsive and dynamic custom WordPress theme designed for Latheefiya English School Payyanur.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: latheefiya-theme

This theme utilizes CSS custom variables and semantic custom blocks, ensuring that headers, layouts, colors, and dynamic page lists are editable through custom fields or custom templates.
*/

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800&family=Open+Sans:wght@400;500;600;700&display=swap');

:root {
    --primary-dark: #002244;
    --primary-blue: #003366;
    --primary-light: #0d4b8a;
    --gold: #FFCC00;
    --gold-dark: #e6b800;
    --gold-light: #ffe066;
    --bg-light: #F8FAFC;
    --bg-white: #FFFFFF;
    --text-main: #334155;
    --text-dark: #0F172A;
    --text-muted: #64748B;
    --accent-green: #10B981;
    --accent-green-hover: #059669;
    --danger: #EF4444;
    --card-shadow: 0 10px 30px -10px rgba(0, 51, 102, 0.08);
    --hover-shadow: 0 20px 40px -15px rgba(0, 51, 102, 0.15);
    --max-width: 1200px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --border-radius: 12px;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Open Sans', sans-serif;
    background-color: var(--bg-light);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Montserrat', sans-serif;
    color: var(--text-dark);
    font-weight: 700;
    line-height: 1.25;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul {
    list-style: none;
}

.text-center { text-align: center; }

.section-title {
    font-size: 2.25rem;
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background-color: var(--gold);
    margin: 10px auto 0;
    border-radius: 2px;
}

.section-subtitle {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 700px;
    margin: 0 auto 3rem;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.75rem;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    border-radius: 30px;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
    text-align: center;
}

.btn-primary {
    background-color: var(--gold);
    color: var(--primary-dark);
}

.btn-primary:hover {
    background-color: var(--gold-dark);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 204, 0, 0.4);
}

.btn-secondary {
    background-color: transparent;
    color: var(--bg-white);
    border-color: var(--bg-white);
}

.btn-secondary:hover {
    background-color: var(--bg-white);
    color: var(--primary-blue);
    transform: translateY(-2px);
}

.btn-accent {
    background-color: var(--accent-green);
    color: var(--bg-white);
}

.btn-accent:hover {
    background-color: var(--accent-green-hover);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(16, 185, 129, 0.4);
}

.btn-outline {
    background-color: transparent;
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}

.btn-outline:hover {
    background-color: var(--primary-blue);
    color: var(--bg-white);
    transform: translateY(-2px);
}

/* Top bar contact details */
.top-bar {
    background-color: var(--primary-dark);
    color: rgba(255, 255, 255, 0.85);
    padding: 8px 0;
    font-size: 0.85rem;
    font-family: 'Montserrat', sans-serif;
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-bar-info span {
    margin-right: 20px;
}

.top-bar-info svg {
    width: 14px;
    height: 14px;
    vertical-align: middle;
    margin-right: 6px;
    fill: var(--gold);
}

.top-bar-socials a {
    margin-left: 15px;
    color: rgba(255, 255, 255, 0.85);
}

.top-bar-socials a:hover {
    color: var(--gold);
}

.top-bar-socials svg {
    width: 16px;
    height: 16px;
    vertical-align: middle;
    fill: currentColor;
}

/* Main Navigation Header */
header.main-header {
    background-color: var(--bg-white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: var(--transition);
}

header.main-header.scrolled {
    padding: 5px 0;
    box-shadow: 0 5px 20px rgba(0, 34, 68, 0.1);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--primary-blue), var(--primary-light));
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 2px solid var(--gold);
}

.logo-text h1 {
    font-size: 1.25rem;
    color: var(--primary-dark);
    margin: 0;
    line-height: 1.1;
    font-weight: 800;
}

.logo-text span {
    font-size: 0.75rem;
    color: var(--text-muted);
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* Dynamic WP Navigation Links */
.nav-menu {
    display: flex;
    align-items: center;
    gap: 25px;
}

.nav-menu li {
    position: relative;
}

.nav-menu a {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--primary-dark);
    padding: 10px 0;
    display: block;
}

.nav-menu a:hover, .nav-menu .current-menu-item > a {
    color: var(--primary-light);
}

.nav-menu li.menu-item-has-children:hover .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--bg-white);
    box-shadow: 0 10px 25px rgba(0, 34, 68, 0.15);
    border-radius: 8px;
    padding: 10px 0;
    min-width: 220px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: var(--transition);
    border-top: 3px solid var(--primary-blue);
    z-index: 999;
}

.sub-menu li {
    width: 100%;
}

.sub-menu a {
    padding: 8px 20px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-main);
}

.sub-menu a:hover {
    background-color: rgba(0, 51, 102, 0.05);
    color: var(--primary-blue);
    padding-left: 25px;
}

/* Hamburger button */
.hamburger {
    display: none;
    cursor: pointer;
    background: none;
    border: none;
}

.hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--primary-dark);
    margin: 5px 0;
    transition: var(--transition);
}

section {
    padding: 80px 0;
}

section.bg-alt {
    background-color: var(--bg-white);
}

/* Hero Section */
.hero-slider {
    position: relative;
    height: 70vh;
    min-height: 500px;
    overflow: hidden;
    background-color: var(--primary-dark);
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    display: flex;
    align-items: center;
}

.slide.active {
    opacity: 1;
    z-index: 10;
}

.slide-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(0, 34, 68, 0.85), rgba(0, 34, 68, 0.4));
    z-index: 2;
}

.slide-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: 1;
}

.slide-content {
    position: relative;
    z-index: 3;
    color: var(--bg-white);
    max-width: 750px;
}

.slide-content h2 {
    font-size: 3rem;
    color: var(--bg-white);
    margin-bottom: 20px;
}

.slide-content h2 span {
    color: var(--gold);
}

.slide-content p {
    font-size: 1.15rem;
    margin-bottom: 30px;
    color: rgba(255, 255, 255, 0.9);
}

.slide-actions {
    display: flex;
    gap: 15px;
}

/* Slider Controls */
.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.4);
    border: none;
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 20;
    display: flex;
    justify-content: center;
    align-items: center;
}

.slider-btn:hover {
    background-color: var(--gold);
    color: var(--primary-dark);
}

.slider-prev { left: 20px; }
.slider-next { right: 20px; }

.slider-btn svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

.slider-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 20;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
}

.dot.active {
    background-color: var(--gold);
    width: 28px;
    border-radius: 6px;
}

/* Welcome Grid */
.welcome-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 50px;
    align-items: center;
}

.welcome-content h3 {
    font-size: 1.8rem;
    color: var(--primary-blue);
    margin-bottom: 15px;
}

.welcome-content p {
    margin-bottom: 20px;
    color: var(--text-main);
    font-size: 1.05rem;
}

.welcome-image-container {
    position: relative;
}

.welcome-img {
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
    border: 8px solid var(--bg-white);
}

.welcome-badge {
    position: absolute;
    bottom: -20px;
    left: -20px;
    background-color: var(--primary-blue);
    color: var(--bg-white);
    padding: 20px;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
    border-left: 5px solid var(--gold);
}

.welcome-badge .badge-num {
    font-family: 'Montserrat', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    color: var(--gold);
    line-height: 1;
}

.welcome-badge .badge-text {
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* Highlights Grid */
.highlights-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 20px;
}

.highlight-card {
    background-color: var(--bg-white);
    padding: 40px 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
    transition: var(--transition);
    border-bottom: 4px solid transparent;
}

.highlight-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--hover-shadow);
    border-bottom-color: var(--gold);
}

.highlight-icon-wrapper {
    width: 70px;
    height: 70px;
    border-radius: 18px;
    background-color: rgba(0, 51, 102, 0.05);
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 25px;
    color: var(--primary-blue);
    transition: var(--transition);
}

.highlight-card:hover .highlight-icon-wrapper {
    background-color: var(--primary-blue);
    color: var(--gold);
}

.highlight-icon-wrapper svg {
    width: 32px;
    height: 32px;
    fill: currentColor;
}

.highlight-card h4 {
    font-size: 1.3rem;
    margin-bottom: 12px;
    color: var(--primary-dark);
}

.highlight-card p {
    color: var(--text-muted);
}

/* Stats Section */
.stats-section {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-blue));
    color: var(--bg-white);
    padding: 60px 0;
    text-align: center;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 40px;
}

.stat-item {
    padding: 10px;
}

.stat-number {
    font-family: 'Montserrat', sans-serif;
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--gold);
    margin-bottom: 5px;
    display: block;
}

.stat-label {
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.85);
}

/* Page Headers */
.page-header {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-blue));
    color: var(--bg-white);
    padding: 70px 0;
    text-align: center;
    position: relative;
    border-bottom: 4px solid var(--gold);
}

.page-header h2 {
    color: var(--bg-white);
    font-size: 2.5rem;
    margin-bottom: 10px;
}

/* Leadership section cards */
.leadership-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 40px;
}

.leader-card {
    background-color: var(--bg-white);
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.leader-image-wrapper {
    height: 350px;
    overflow: hidden;
    background-color: #e2e8f0;
}

.leader-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
}

.leader-info {
    padding: 30px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.leader-info h3 {
    font-size: 1.4rem;
    color: var(--primary-dark);
    margin-bottom: 5px;
}

.leader-title {
    font-family: 'Montserrat', sans-serif;
    color: var(--primary-light);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 20px;
}

.leader-message {
    color: var(--text-main);
    font-size: 0.95rem;
    font-style: italic;
    position: relative;
}

.leader-message::before {
    content: '“';
    font-family: Georgia, serif;
    font-size: 4rem;
    color: rgba(0, 51, 102, 0.1);
    position: absolute;
    top: -20px;
    left: -15px;
    line-height: 1;
}

/* Contact Layout */
.contact-layout {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 50px;
}

.contact-info-panel {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.info-card {
    background-color: var(--bg-white);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
    display: flex;
    gap: 20px;
}

.info-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background-color: rgba(0, 51, 102, 0.05);
    color: var(--primary-blue);
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
}

.info-icon svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

.info-details h4 {
    margin-bottom: 5px;
    color: var(--primary-dark);
}

.contact-form-panel {
    background-color: var(--bg-white);
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.form-control {
    width: 100%;
    padding: 12px 18px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    color: var(--text-dark);
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-light);
    box-shadow: 0 0 0 4px rgba(13, 75, 138, 0.1);
}

textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

.form-message {
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-weight: 600;
    display: none;
}

.form-message.success {
    display: block;
    background-color: rgba(16, 185, 129, 0.1);
    color: var(--accent-green-hover);
    border-left: 4px solid var(--accent-green);
}

/* Table Calendar */
.calendar-table-wrapper {
    overflow-x: auto;
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
    background-color: var(--bg-white);
}

.calendar-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px;
}

.calendar-table th {
    background-color: var(--primary-blue);
    color: var(--bg-white);
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    text-align: left;
    padding: 18px 20px;
}

.calendar-table td {
    padding: 15px 20px;
    border-bottom: 1px solid #e2e8f0;
}

.calendar-table tr:nth-child(even) {
    background-color: var(--bg-light);
}

/* Footer Styling */
footer.main-footer {
    background-color: var(--primary-dark);
    color: rgba(255, 255, 255, 0.75);
    padding: 70px 0 20px;
    font-size: 0.95rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr 1fr;
    gap: 50px;
    margin-bottom: 50px;
}

.footer-col h3 {
    color: var(--bg-white);
    font-size: 1.25rem;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 10px;
}

.footer-col h3::after {
    content: '';
    display: block;
    width: 40px;
    height: 3px;
    background-color: var(--gold);
    position: absolute;
    bottom: 0;
    left: 0;
}

.footer-logo-desc p {
    margin: 20px 0;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
}

.footer-links a:hover {
    color: var(--gold);
    padding-left: 5px;
}

.footer-contact li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 15px;
}

.footer-contact svg {
    width: 18px;
    height: 18px;
    fill: var(--gold);
    flex-shrink: 0;
    margin-top: 3px;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-social-links {
    display: flex;
    gap: 15px;
}

.footer-social-links a {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.06);
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--bg-white);
}

.footer-social-links a:hover {
    background-color: var(--gold);
    color: var(--primary-dark);
}

.footer-social-links svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

/* Media Queries */
@media (max-width: 992px) {
    .hamburger { display: block; }
    .nav-menu {
        position: fixed;
        top: 110px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 110px);
        background-color: var(--bg-white);
        flex-direction: column;
        align-items: flex-start;
        padding: 40px;
        gap: 20px;
        box-shadow: 0 10px 15px rgba(0, 0, 0, 0.05);
        transition: var(--transition);
        overflow-y: auto;
        z-index: 999;
    }
    .nav-menu.open { left: 0; }
    .sub-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        padding-left: 20px;
        display: none;
        border-top: none;
    }
    .nav-menu li:hover .sub-menu { display: block; }
    .welcome-grid, .contact-layout { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
}
