/* ==============================
   Variables & Themes
============================== */
:root {
  --bg1: #2a2a2a;
  --bg2: #3a3a3a;
  --text: #ffffff;
  --accent: #FFD700;
  --card: #444;
  --motto: #ffffff;
  --shadow: rgba(255, 215, 0, 0.3);
  --gold: #FFD700;
  --petrol: #005f5f;
}

[data-theme="light"] {
  --bg1: #fdfdfd;
  --bg2: #f0f0f0;
  --text: #000000;
  --accent: #005f5f;
  --card: #ffffff;
  --motto: #000000;
  --shadow: rgba(0, 95, 95, 0.3);
  --gold: #005f5f;
}

/* ==============================
   Global Reset & Transitions
============================== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  transition: background-color 0.4s ease, color 0.4s ease, border-color 0.4s ease;
}

body {
  font-family: "Times New Roman", Times, serif;
  font-size: 16px;
  line-height: 1.6;
  background: linear-gradient(135deg, var(--bg1), var(--bg2));
  background-size: 400% 400%;
  animation: backgroundShift 20s ease infinite;
  color: var(--text);
}

body::before {
  content: "";
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: url('hero-bg.jpg') center/cover no-repeat;
  opacity: 0.12;
  z-index: -2;
}

@keyframes backgroundShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* ==============================
   Top Bar
============================== */
.top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.8rem 1.2rem;
  background: var(--card);
  border-bottom: 1px solid rgba(255,215,0,0.2);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.site-title {
  font-size: 1.3rem;
  font-weight: bold;
  color: var(--gold);
}

.nav-links ul {
  list-style: none;
  display: flex;
  gap: 1.5rem;
}

.header-link {
  font-size: 1.1rem;
  font-weight: bold;
  text-decoration: none;
  color: var(--gold);
}

[data-theme="light"] .header-link { color: var(--petrol); }

.nav-links a:hover,
.nav-links a:focus {
  text-decoration: underline;
}

/* ==============================
   Hero Section
============================== */
.hero {
  text-align: center;
  margin: 2rem auto;
  animation: fadeIn 1.5s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

.hero h1.hero-name {
  font-size: 2rem;
  font-weight: bold;
  color: var(--gold);
}

[data-theme="light"] .hero h1.hero-name { color: var(--petrol); }

.motto {
  font-size: 1.2rem;
  color: var(--motto);
  margin-bottom: 25px;
}

.profile-pic {
  display: block;
  margin: 0 auto 20px;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--gold);
  box-shadow: 0 0 10px var(--shadow);
  transition: transform 0.3s;
}

.profile-pic:hover { transform: scale(1.05); }

/* ==============================
   Cards
============================== */
.card {
  background: var(--card);
  padding: 1rem;
  margin: 1rem auto;
  border-radius: 6px;
  max-width: 900px;
  opacity: 0;
  transform: translateY(20px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.card.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ==============================
   Sections Headers
============================== */
.section-header {
  font-size: 1.2rem;
  font-weight: bold;
  color: var(--gold);
}

[data-theme="light"] .section-header { color: var(--petrol); }

/* ==============================
   About Me Text
============================== */
.about-text {
  font-size: 1.1rem;
  line-height: 1.3;
}

.language-tags {
  display: flex;
  gap: 0.8rem;
  margin-top: 0.5rem;
}

.lang-tag {
  font-weight: bold;
  color: var(--gold);
}

.level-tag {
  color: #fff;
}

[data-theme="light"] .lang-tag { color: var(--petrol); }
[data-theme="light"] .level-tag { color: #000; }

/* ==============================
   Skills List
============================== */
.skills-list li {
  margin: 6px 0;
  font-size: 17px;
}

.skills-list li::before {
  content: "";
}

/* ==============================
   Projects
============================== */
.project-title {
  font-size: 1.1rem;
}

.github-link {
  color: var(--gold);
}

[data-theme="light"] .github-link { color: var(--petrol); }

/* ==============================
   Contact
============================== */
.contact-label {
  font-weight: bold;
  color: var(--gold);
}

.contact-value {
  font-weight: normal;
}

[data-theme="light"] .contact-label { color: var(--petrol); }

/* ==============================
   CTA Buttons
============================== */
.cta-btn {
  display: inline-block;
  margin: 0.5rem;
  padding: 0.8rem 1.8rem;
  background: var(--accent);
  color: #000;
  font-weight: normal;
  border-radius: 6px;
  text-decoration: none;
  box-shadow: 0 0 6px var(--shadow);
  transition: background 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

.cta-btn:hover,
.cta-btn:focus {
  background: #fff8dc;
  box-shadow: 0 0 8px var(--shadow);
  transform: translateY(-2px);
  outline: none;
}

/* ==============================
   Separator & Footer
============================== */
.separator {
  height: 2px;
  background: var(--accent);
  margin: 2rem auto;
  width: 80%;
  opacity: 0.5;
}

footer {
  text-align: center;
  margin-top: 2rem;
  padding: 1rem;
  font-size: 0.9rem;
  color: var(--text);
  border-top: 1px solid rgba(255,215,0,0.2);
  background: var(--card);
  border-radius: 6px 6px 0 0;
}

/* ==============================
   Final Note
============================== */
.wrapup-message { font-weight: normal; text-align: center; margin-top: 10px; }

/* ==============================
   Mobile Optimization
============================== */
@media (max-width: 700px) {
  .top-bar { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
  .nav-links ul { flex-wrap: wrap; gap: 0.8rem; }
  h1 { font-size: 24px; }
  h2 { font-size: 18px; }
  .profile-pic { width: 120px; height: 120px; }
  .motto { font-size: 1.2rem; }
  .card { margin: 1rem; }
  .lang-tag, .level-tag { font-size: 12px; padding: 2px 6px; }
  .cta-btn { padding: 0.5rem 1rem; font-size: 0.85rem; }
  .contact-label, .contact-value { font-size: 14px; }
  .wrapup-message { font-size: 0.95rem; }
}
