:root {
  --blue-dark: #0000A3;
  --blue-mid: #0067B3;
  --blue-light: #40B0DF;
  --yellow: #FFD53D;
  --bg-light: #eef2f5;
  --bg-dark: #080a18;
  --text-light: #e0e5f0;
  --text-dark: #1a202c;
  --card-bg-light: rgba(255, 255, 255, 0.2);
  --card-bg-dark: rgba(20, 20, 40, 0.4);
  --shadow-light: rgba(0, 0, 0, 0.1);
  --shadow-dark: rgba(0, 0, 0, 0.5);
  --glow-light: rgba(64, 176, 223, 0.5);
  --glow-dark: rgba(255, 213, 61, 0.7);
}

html {
    scroll-behavior: smooth;
}

body {
  font-family: 'Inter', sans-serif;
  margin: 0;
  background-color: var(--bg-light);
  color: var(--text-dark);
  transition: background-color 0.5s ease, color 0.5s ease;
  overflow-x: hidden;
}

body.dark-mode {
  --bg-light: var(--bg-dark);
  --text-dark: var(--text-light);
  --card-bg-light: var(--card-bg-dark);
  --shadow-light: var(--shadow-dark);
  --glow-light: var(--glow-dark);
}

#particles-js {
    position: fixed;
    width: 100%;
    height: 100%;
    z-index: -1;
}

/* --- Header & Hero --- */
.hero {
    color: white;
    height: 100vh;
    display: flex;
    flex-direction: column;
    text-align: center;
    background: linear-gradient(145deg, rgba(8, 10, 24, 0.8), rgba(0, 103, 179, 0.7));
    position: relative;
    overflow: hidden;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    width: 100%;
    box-sizing: border-box;
    background: rgba(0,0,0,0.1);
    backdrop-filter: blur(5px);
}

.logo {
    width: 150px;
    height: auto;
    z-index: 10;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 2rem;
    margin: 0;
    padding: 0;
}

.nav-links a {
    color: white;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: color 0.3s, text-shadow 0.3s;
}

.nav-links a:hover {
    color: var(--yellow);
    text-shadow: 0 0 10px var(--yellow);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.header-social-links {
    display: flex;
    gap: 1rem;
}

.header-social-links a {
    color: white;
    transition: color 0.3s, transform 0.3s;
}

.header-social-links a:hover {
    color: var(--yellow);
    transform: scale(1.2);
}

.header-social-links svg {
    width: 20px;
    height: 20px;
}

.hero-content {
    margin: auto;
    max-width: 800px;
    padding: 1rem;
}

.typing-text-container {
    font-family: 'Poppins', sans-serif;
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    min-height: 100px;
    text-shadow: 0 0 20px rgba(255,255,255,0.3);
}

.cursor {
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    from, to { opacity: 1 }
    50% { opacity: 0 }
}

.hero-subtitle {
    font-size: 1.2rem;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto 2rem;
    opacity: 0.9;
}

.btn {
    display: inline-block;
    padding: 1rem 2rem;
    background: var(--yellow);
    color: var(--blue-dark);
    border-radius: 50px;
    font-weight: bold;
    text-decoration: none;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0,0,0,0.25);
}

.btn:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 10px 30px rgba(255, 213, 61, 0.5);
}

/* --- Sections & Cards --- */
main {
    padding: 5rem 2rem;
    position: relative;
    z-index: 1;
    background-color: var(--bg-light);
}

.content-section {
    margin-bottom: 5rem;
}

.section-title-container {
    text-align: center;
    margin-bottom: 3rem;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.section-title-container.visible {
    opacity: 1;
    transform: translateY(0);
}

.section-title {
    font-family: 'Poppins', sans-serif;
    font-size: 2.8rem;
    font-weight: 700;
    display: inline-block;
    position: relative;
    color: var(--text-dark);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 70px;
    height: 4px;
    background: var(--yellow);
    border-radius: 2px;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
}

.glass-card {
    background: var(--card-bg-light);
    padding: 2.5rem;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: 0 10px 40px 0 var(--shadow-light);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: var(--text-dark);
    transition: transform 0.4s ease, background 0.4s ease, box-shadow 0.4s ease;
    opacity: 0;
    transform: translateY(50px);
}

body.dark-mode .glass-card {
    border: 1px solid rgba(64, 176, 223, 0.4);
}

.glass-card.visible {
    opacity: 1;
    transform: translateY(0);
    transition-delay: calc(0.1s * var(--card-index, 1));
}

.glass-card:hover {
    transform: translateY(-12px);
    box-shadow: 0 20px 50px 0 var(--shadow-light);
}

.glass-card h3 {
    font-family: 'Poppins', sans-serif;
    color: var(--blue-mid);
    margin-top: 0;
    font-size: 1.5rem;
}

body.dark-mode .glass-card h3 {
    color: var(--blue-light);
}

/* --- Contact Form --- */
.contact-card {
    max-width: 600px;
    margin: auto;
    text-align: center;
}

.contact-card p {
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.contact-card form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    position: relative;
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 1rem;
    background: transparent;
    border: 1px solid var(--blue-mid);
    border-radius: 8px;
    color: var(--text-dark);
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
}

body.dark-mode .form-group input, body.dark-mode .form-group textarea {
    border-color: var(--blue-light);
}

.form-group label {
    position: absolute;
    top: 1rem;
    left: 1rem;
    color: var(--text-dark);
    opacity: 0.7;
    transition: all 0.3s ease;
    pointer-events: none;
}

.form-group input:focus, .form-group textarea:focus,
.form-group input:valid, .form-group textarea:valid {
    outline: none;
    border-color: var(--yellow);
    box-shadow: 0 0 15px var(--glow-light);
}

.form-group input:focus + label, .form-group textarea:focus + label,
.form-group input:valid + label, .form-group textarea:valid + label {
    top: -0.75rem;
    left: 0.75rem;
    font-size: 0.8rem;
    background: var(--bg-light);
    padding: 0 0.25rem;
    color: var(--yellow);
}

body.dark-mode .form-group input:focus + label,
body.dark-mode .form-group textarea:focus + label,
body.dark-mode .form-group input:valid + label,
body.dark-mode .form-group textarea:valid + label {
    background: var(--bg-dark);
}

/* --- Footer --- */
footer {
    text-align: center;
    padding: 3rem 2rem;
    background-color: var(--bg-dark);
    color: var(--text-light);
    position: relative;
    z-index: 1;
}

.footer-contact {
    margin-bottom: 1rem;
}

.footer-contact p {
    margin: 0.5rem 0;
}

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

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

/* --- Theme Toggle --- */
.theme-toggle-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    z-index: 10;
}

.theme-toggle-btn svg {
    width: 24px;
    height: 24px;
    transition: transform 0.5s ease;
}

.theme-toggle-btn .moon { display: none; }
.theme-toggle-btn .sun { display: block; }

body.dark-mode .theme-toggle-btn .moon { display: block; }
body.dark-mode .theme-toggle-btn .sun { display: none; }

body.dark-mode .theme-toggle-btn {
    color: var(--yellow);
}

/* --- Responsive Design --- */
@media (max-width: 768px) {
    .nav-links, .header-social-links {
        display: none; 
    }

    .typing-text-container {
        font-size: 2.5rem;
        min-height: 80px;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .section-title {
        font-size: 2.2rem;
    }
}
