/* RVJ Website Styles - With Dark/Light Theme Support */

/* Import Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* CSS Variables for Theming */
:root {
    /* Light Theme (Default) */
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    --text-primary: #1e293b;
    --text-secondary: #475569;
    --text-tertiary: #64748b;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
    
    /* Brand Colors (constant) */
    --rvj-sage: #a3b19b;
    --rvj-slate: #5b7280;
    --rvj-terracotta: #ad7c65;
    --rvj-dark: #2c3e50;
    
    /* Theme-aware accent */
    --accent-bg: rgba(163, 177, 155, 0.1);
    --nav-glass-bg: rgba(255, 255, 255, 0.95);
    --nav-border: rgba(0, 0, 0, 0.05);
    --card-bg: #ffffff;
    --card-hover-bg: #f8fafc;
}

[data-theme="dark"] {
    /* Dark Theme */
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-tertiary: #334155;
    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --text-tertiary: #94a3b8;
    --border-color: #334155;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.5);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.5);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.5);
    
    --accent-bg: rgba(163, 177, 155, 0.15);
    --nav-glass-bg: rgba(15, 23, 42, 0.95);
    --nav-border: rgba(255, 255, 255, 0.1);
    --card-bg: #1e293b;
    --card-hover-bg: #334155;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    scroll-behavior: smooth;
    transition: background-color 0.3s ease, color 0.3s ease;
}

html[dir="rtl"] body {
    font-family: 'Tahoma', 'Arial', sans-serif;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-primary);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

a {
    color: var(--rvj-slate);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--rvj-terracotta);
}

/* Container */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
}

@media (min-width: 768px) {
    .container {
        padding: 0 2rem;
    }
}

/* Navigation */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: var(--nav-glass-bg);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--nav-border);
    transition: all 0.3s ease;
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
}

.logo-img {
    height: 48px;
    width: auto;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-text .brand-name {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}

.logo-text .brand-tagline {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-tertiary);
    margin-top: 0.25rem;
}

.nav-links {
    display: none;
    gap: 2rem;
    align-items: center;
}

@media (min-width: 768px) {
    .nav-links {
        display: flex;
    }
}

.nav-links a {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: color 0.3s ease;
    position: relative;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--rvj-slate);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--rvj-slate);
    transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* Theme Toggle */
.theme-toggle {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    background: var(--accent-bg);
    border-color: var(--rvj-sage);
}

.theme-toggle svg {
    width: 20px;
    height: 20px;
    fill: var(--text-primary);
}

/* Language Selector */
.language-selector {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    font-size: 0.875rem;
    border-radius: 8px;
    padding: 0.5rem 0.75rem;
    cursor: pointer;
    outline: none;
    transition: all 0.3s ease;
}

.language-selector:hover,
.language-selector:focus {
    border-color: var(--rvj-slate);
    background: var(--accent-bg);
}

/* Mobile Menu Button */
.mobile-menu-btn {
    display: flex;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
}

@media (min-width: 768px) {
    .mobile-menu-btn {
        display: none;
    }
}

/* Mobile Menu */
.mobile-menu {
    display: none;
    background: var(--card-bg);
    border-top: 1px solid var(--border-color);
    padding: 1rem;
    box-shadow: var(--shadow-lg);
}

.mobile-menu.active {
    display: block;
}

.mobile-menu a {
    display: block;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-weight: 500;
    color: var(--text-primary);
    transition: background-color 0.3s ease;
}

.mobile-menu a:hover,
.mobile-menu a.active {
    background-color: var(--accent-bg);
    color: var(--rvj-slate);
}

/* Hero Section */
.hero {
    padding: 8rem 1rem 5rem;
    text-align: center;
    background: var(--bg-secondary);
    position: relative;
    overflow: hidden;
}

.hero::before,
.hero::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    opacity: 0.1;
    filter: blur(60px);
}

.hero::before {
    top: -5rem;
    right: -5rem;
    width: 24rem;
    height: 24rem;
    background: var(--rvj-sage);
}

.hero::after {
    bottom: -5rem;
    left: -5rem;
    width: 20rem;
    height: 20rem;
    background: var(--rvj-slate);
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--rvj-slate);
    margin-bottom: 2rem;
    box-shadow: var(--shadow-sm);
}

.hero h1 {
    max-width: 900px;
    margin: 0 auto 1.5rem;
    font-size: clamp(2rem, 5vw, 3.5rem);
}

.hero p {
    max-width: 700px;
    margin: 0 auto;
    font-size: clamp(1.125rem, 2.5vw, 1.5rem);
    font-weight: 300;
}

/* Section Styles */
section {
    padding: 5rem 1rem;
}

.section-label {
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--rvj-terracotta);
    margin-bottom: 0.75rem;
}

.section-title {
    font-size: clamp(1.875rem, 4vw, 2.5rem);
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

/* Cards */
.card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
}

.card:hover {
    background: var(--card-hover-bg);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.card-icon {
    width: 56px;
    height: 56px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.card-icon svg,
.card-icon i {
    font-size: 1.5rem;
}

.card h4 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.card p {
    font-size: 1rem;
    line-height: 1.7;
}

/* Grid Layouts */
.grid {
    display: grid;
    gap: 2rem;
}

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

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

@media (min-width: 768px) {
    .grid-2 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .grid-3 {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Feature Boxes */
.feature-box {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 2rem;
    border: 1px solid var(--border-color);
}

.feature-box h4 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

/* Stats Box */
.stats-box {
    background: var(--bg-secondary);
    padding: 3rem 2rem;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}

.stats-number {
    font-size: clamp(3rem, 8vw, 5rem);
    font-weight: 700;
    color: var(--text-primary);
    display: block;
    margin-bottom: 1rem;
}

/* Dark Section */
.dark-section {
    background: var(--rvj-dark);
    color: #ffffff;
    position: relative;
    overflow: hidden;
}

[data-theme="dark"] .dark-section {
    background: var(--bg-tertiary);
}

.dark-section h2,
.dark-section h3,
.dark-section h4,
.dark-section p {
    color: #ffffff;
}

[data-theme="dark"] .dark-section h2,
[data-theme="dark"] .dark-section h3,
[data-theme="dark"] .dark-section h4,
[data-theme="dark"] .dark-section p {
    color: var(--text-primary);
}

.dark-section .card {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.dark-section .card:hover {
    background: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .dark-section .card {
    background: var(--card-bg);
    border-color: var(--border-color);
}

[data-theme="dark"] .dark-section .card:hover {
    background: var(--card-hover-bg);
}

/* About Section */
.about-content {
    display: flex;
    flex-direction: column;
    gap: 3rem;
    align-items: center;
}

@media (min-width: 768px) {
    .about-content {
        flex-direction: row;
    }
}

.about-image {
    flex: 0 0 300px;
}

.about-image img {
    width: 100%;
    height: auto;
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
}

.about-text {
    flex: 1;
}

/* Contact Card */
.contact-card {
    background: var(--bg-secondary);
    padding: 3rem 2rem;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    text-align: center;
    max-width: 400px;
    margin: 0 auto;
}

.contact-avatar {
    width: 80px;
    height: 80px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    box-shadow: var(--shadow-sm);
}

.contact-avatar svg,
.contact-avatar i {
    font-size: 2rem;
    color: var(--rvj-slate);
}

.contact-card h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.contact-card .role {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--rvj-slate);
    margin-bottom: 1.5rem;
}

.contact-card .email {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--rvj-terracotta);
    font-weight: 600;
    font-size: 1.125rem;
    margin-bottom: 1rem;
    transition: color 0.3s ease;
}

.contact-card .email:hover {
    color: var(--rvj-slate);
}

.contact-card .location {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-tertiary);
}

/* Footer */
footer {
    background: var(--card-bg);
    border-top: 1px solid var(--border-color);
    padding: 4rem 1rem 2rem;
}

.footer-content {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    align-items: center;
    text-align: center;
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
    font-size: 0.875rem;
    color: var(--text-tertiary);
}

@media (min-width: 768px) {
    .footer-bottom {
        flex-direction: row;
        justify-content: space-between;
    }
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    opacity: 0.5;
}

.footer-logo img {
    height: 24px;
    width: auto;
    filter: grayscale(1);
}

/* RTL Support */
html[dir="rtl"] .nav-container,
html[dir="rtl"] .footer-bottom {
    flex-direction: row-reverse;
}

html[dir="rtl"] .logo-area,
html[dir="rtl"] .nav-actions,
html[dir="rtl"] .hero-badge,
html[dir="rtl"] .contact-card .email,
html[dir="rtl"] .contact-card .location,
html[dir="rtl"] .footer-logo {
    flex-direction: row-reverse;
}

html[dir="rtl"] .about-content {
    flex-direction: column-reverse;
}

@media (min-width: 768px) {
    html[dir="rtl"] .about-content {
        flex-direction: row-reverse;
    }
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Focus Styles */
a:focus,
button:focus,
select:focus {
    outline: 2px solid var(--rvj-slate);
    outline-offset: 2px;
}

/* Smooth Transitions */
.fade-transition {
    transition: opacity 0.3s ease-in-out;
}

.fade-out {
    opacity: 0;
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
