/* Main CSS – minimal theme aligned with simplified HTML
   Sections included: variables, base, header/nav, preloader, scroll-top,
   hero, about, skills (logo grid), CV/resume, portfolio (no filters), contact, footer
*/

/* ------------------------------
   Fonts & Color System
------------------------------ */
:root {
  --default-font: "Roboto", system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
  --heading-font: "Ubuntu", sans-serif;
  --nav-font: "Nunito", sans-serif;

  --background-color: #1f1f1f;
  --surface-color: #232323;
  --heading-color: #ffffff;
  --default-color: #ffffff;
  --accent-color: #ececec;
  --contrast-color: #310606;

  --nav-color: rgba(236, 236, 236, 0.6);
  --nav-hover-color: #ffffff;
  --nav-mobile-background-color: #393939;
  --nav-dropdown-background-color: #393939;
  --nav-dropdown-color: #ffffff;
  --nav-dropdown-hover-color: #ececec;

  scroll-behavior: smooth;
}

/* Color presets for sections */
.light-background {
  --background-color: #2c2c2c;
  --surface-color: #323232;
}
.dark-background {
  --background-color: #040b14;
  --default-color: #ffffff;
  --heading-color: #ffffff;
  --surface-color: #151f2b;
  --contrast-color: #ffffff;
}

/* ------------------------------
   Base
------------------------------ */
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  color: var(--default-color);
  background-color: var(--background-color);
  font-family: var(--default-font);
  line-height: 1.5;
}

a {
  color: var(--accent-color);
  text-decoration: none;
  transition: 0.3s;
}
a:hover { color: color-mix(in srgb, var(--accent-color), transparent 25%); }

h1, h2, h3, h4, h5, h6 {
  color: var(--heading-color);
  font-family: var(--heading-font);
  margin: 0 0 .5rem 0;
}

section, .section {
  color: var(--default-color);
  background-color: var(--background-color);
  padding: 60px 0;
  overflow: clip;
}

/* ------------------------------
   Header (sidebar)
------------------------------ */
.header {
  --background-color: #1b1b1b;
  --contrast-color: #444;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  padding: 0 15px;
  width: 300px;
  z-index: 997;
  overflow-y: auto;
  transition: all .3s ease-in-out;
  color: var(--default-color);
}
.header .header-container {
  border-radius: 20px;
  padding: 15px;
  background-color: var(--background-color);
  border: 1px solid color-mix(in srgb, var(--default-color), transparent 80%);
}
.header .social-links {
  margin: 0 0 10px 0;
}
.header .social-links a {
  font-size: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: color-mix(in srgb, var(--default-color), transparent 90%);
  color: var(--default-color);
  margin: 0 2px;
  border-radius: 50%;
  width: 40px; height: 40px;
}
.header .social-links a:hover {
  color: var(--contrast-color);
  background: var(--accent-color);
}

@media (min-width: 1200px) {
  .header ~ main,
  .header ~ #footer { margin-left: 330px; }
}
@media (max-width: 1199px) {
  .header { left: -100%; }
}
.header.header-show { left: 0; }

.header .header-toggle {
  color: var(--contrast-color);
  background-color: var(--accent-color);
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px; height: 40px;
  border-radius: 50%;
  cursor: pointer;
  position: fixed;
  top: 15px; right: 15px;
  z-index: 9999;
}

/* Nav */
.navmenu { padding: 0; width: 100%; }
.navmenu ul { list-style: none; padding: 0 0 20px 0; margin: 0; }
.navmenu a {
  color: var(--nav-color);
  padding: 15px 10px;
  font-family: var(--nav-font);
  font-size: 16px; font-weight: 400;
  display: flex; align-items: center;
  white-space: nowrap;
}
.navmenu a .navicon { font-size: 20px; margin-right: 10px; }
.navmenu a:hover,
.navmenu a.active { color: var(--nav-hover-color); }
.navmenu a:hover .navicon,
.navmenu a.active .navicon { color: var(--accent-color); }

/* ------------------------------
   Preloader
------------------------------ */
#preloader {
  position: fixed; inset: 0;
  z-index: 999999;
  overflow: hidden;
  background: var(--background-color);
  transition: opacity .6s ease-out, visibility .6s ease-out;
}
#preloader:before {
  content: "";
  position: fixed;
  top: calc(50% - 30px);
  left: calc(50% - 30px);
  border: 6px solid var(--accent-color);
  border-color: var(--accent-color) transparent var(--accent-color) transparent;
  border-radius: 50%;
  width: 60px; height: 60px;
  animation: preloader-rotate 1.5s linear infinite;
}
@keyframes preloader-rotate {
  0% { transform: rotate(0); }
  100% { transform: rotate(360deg); }
}
body.preload-done #preloader { opacity: 0; visibility: hidden; }

/* ------------------------------
   Scroll-top
------------------------------ */
.scroll-top {
  position: fixed;
  right: 15px; bottom: -15px;
  visibility: hidden; opacity: 0;
  z-index: 99999;
  background-color: var(--accent-color);
  width: 44px; height: 44px;
  border-radius: 50px;
  display: flex; align-items: center; justify-content: center;
  transition: all .4s;
}
.scroll-top i { font-size: 24px; color: var(--contrast-color); }
.scroll-top:hover {
  background-color: color-mix(in srgb, var(--accent-color), transparent 20%);
}
.scroll-top.active { visibility: visible; opacity: 1; bottom: 15px; }

/* Disable AOS delay on mobile */
@media (max-width: 768px) {
  [data-aos-delay] { transition-delay: 0 !important; }
}

/* ------------------------------
   Section titles
------------------------------ */
.section-title {
  text-align: center;
  padding-bottom: 40px;
}
.section-title h2 {
  font-size: 32px; font-weight: 700;
  position: relative;
}
.section-title h2:before,
.section-title h2:after {
  content: "";
  width: 50px; height: 2px;
  background: var(--accent-color);
  display: inline-block;
}
.section-title h2:before { margin: 0 15px 10px 0; }
.section-title h2:after  { margin: 0 0 10px 15px; }
.section-title p { margin: 0; }

/* ------------------------------
   Hero
------------------------------ */
.hero {
  min-height: 100vh;
  position: relative;
  overflow: hidden;
  display: flex; align-items: center;
}
.hero .background-elements {
  position: absolute; inset: 0;
  z-index: 1; overflow: hidden;
}
.hero .bg-circle {
  position: absolute; border-radius: 50%;
  background: linear-gradient(45deg,
    color-mix(in srgb, var(--accent-color), transparent 90%),
    color-mix(in srgb, var(--accent-color), transparent 95%));
  animation: float 6s ease-in-out infinite;
}
.hero .circle-1 { width: 300px; height: 300px; top: 10%; right: 10%; animation-delay: 0s; }
.hero .circle-2 { width: 200px; height: 200px; bottom: 20%; left: 5%;  animation-delay: 2s; }

.hero .hero-content { position: relative; width: 100%; z-index: 2; }
.hero .hero-text h1 { font-size: 56px; font-weight: 800; line-height: 1.1; margin-bottom: 10px; }
.hero .hero-text .lead { font-size: 22px; margin-bottom: 16px; }
.hero .hero-actions { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 20px; }
.hero .hero-actions .btn {
  padding: 12px 26px; font-weight: 600; border-radius: 50px; border: 2px solid;
}
.hero .btn.btn-primary { background: var(--accent-color); color: var(--contrast-color); border-color: var(--accent-color); }
.hero .btn.btn-primary:hover { transform: translateY(-2px); }
.hero .btn.btn-outline { background: transparent; color: var(--accent-color); border-color: var(--accent-color); }
.hero .btn.btn-outline:hover { background: var(--accent-color); color: var(--contrast-color); }

.hero .social-links { display: flex; gap: 12px; margin-top: 10px; }
.hero .social-links a {
  width: 44px; height: 44px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--surface-color);
  color: color-mix(in srgb, var(--default-color), transparent 40%);
}
.hero .social-links a:hover { background: var(--accent-color); color: var(--contrast-color); }

.hero .hero-visual .profile-container { position: relative; width: 400px; height: 400px; }
.hero .profile-background {
  position: absolute; top: 15px; left: 15px; width: 100%; height: 100%;
  background: color-mix(in srgb, var(--accent-color), transparent 90%);
  border-radius: 30px; z-index: 1;
}
.hero .profile-image {
  position: relative; width: 100%; height: 100%;
  object-fit: cover; border-radius: 30px; z-index: 2;
}

@keyframes float {
  0%,100% { transform: translateY(0); }
  50% { transform: translateY(-20px); }
}

@media (max-width: 992px) {
  .hero .hero-text { text-align: center; margin-bottom: 40px; }
  .hero .hero-text h1 { font-size: 42px; }
  .hero .hero-visual .profile-container { width: 320px; height: 320px; }
}

/* ------------------------------
   About
------------------------------ */
.about .profile-card {
  background: linear-gradient(135deg, var(--surface-color) 0%,
    color-mix(in srgb, var(--surface-color), var(--accent-color) 5%) 100%);
  border-radius: 2rem; padding: 2rem; text-align: center;
  border: 1px solid color-mix(in srgb, var(--accent-color), transparent 90%);
}
.about .profile-image {
  width: 160px; height: 160px; margin: 0 auto 1rem;
  border-radius: 50%; overflow: hidden; border: 4px solid var(--accent-color);
}
.about .profile-image img { width: 100%; height: 100%; object-fit: cover; }
.about .profile-badge {
  width: 32px; height: 32px; background: var(--accent-color);
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  margin: 0 auto; transform: translateY(-16px);
}
.about .profile-badge i { color: var(--contrast-color); font-size: 14px; }
.about .profession { color: var(--accent-color); font-weight: 500; }

.about .about-content .badge-text {
  display: inline-block;
  background: linear-gradient(135deg, var(--accent-color),
    color-mix(in srgb, var(--accent-color), var(--heading-color) 20%));
  color: var(--contrast-color);
  padding: .4rem 1.2rem; border-radius: 2rem; font-weight: 600; margin-bottom: 1rem;
}
.about .description p {
  color: color-mix(in srgb, var(--default-color), transparent 20%);
}

/* ------------------------------
   Skills: logo grid only
------------------------------ */
#skills img { max-height: 48px; filter: drop-shadow(0 0 0 rgba(0,0,0,0)); }
#skills .row > .col {
  background: var(--surface-color);
  border: 1px solid color-mix(in srgb, var(--default-color), transparent 90%);
  border-radius: 10px;
  padding: 20px;
  transition: transform .2s ease;
}
#skills .row > .col:hover { transform: translateY(-4px); }

/* ------------------------------
   Resume (CV)
------------------------------ */
.resume .resume-side {
  background: var(--surface-color);
  padding: 1.5rem; border-radius: 10px;
  border: 1px solid color-mix(in srgb, var(--default-color), transparent 90%);
  height: 100%;
}
.resume .resume-section { margin-bottom: 2rem; }
.resume .resume-section h3 { font-size: 1.5rem; font-weight: 700; }
.resume .resume-item {
  padding-left: 1.2rem;
  border-left: 2px solid color-mix(in srgb, var(--accent-color), transparent 80%);
  margin-bottom: 1.25rem; position: relative;
}
.resume .resume-item:before {
  content: ""; position: absolute; width: 12px; height: 12px; border-radius: 50%;
  left: -7px; top: 0; background: var(--accent-color);
}
.resume .company { color: var(--heading-color); }

/* ------------------------------
   Portfolio (no filters, 2 items)
------------------------------ */
.portfolio .portfolio-wrap {
  position: relative; overflow: hidden; border-radius: 12px;
  box-shadow: 0 5px 20px rgba(0,0,0,0.08);
  transition: transform .3s ease;
}
.portfolio .portfolio-wrap:hover { transform: translateY(-5px); }
.portfolio .portfolio-wrap img {
  width: 100%; height: 350px; object-fit: cover;
  transition: transform .6s cubic-bezier(.215,.61,.355,1);
}
.portfolio .portfolio-wrap:hover img { transform: scale(1.06); }
.portfolio .portfolio-info {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 20px;
  background: linear-gradient(to top, rgba(0,0,0,.8), rgba(0,0,0,.15));
}
.portfolio .portfolio-info .category {
  display: inline-block; color: var(--accent-color);
  font-size: 12px; letter-spacing: 1px; text-transform: uppercase;
}
.portfolio .portfolio-info h4 { margin: 6px 0 12px; }
.portfolio .portfolio-links { display: flex; gap: 10px; }
.portfolio .portfolio-links a {
  color: var(--contrast-color);
  width: 40px; height: 40px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: color-mix(in srgb, var(--accent-color), transparent 30%);
}
.portfolio .portfolio-links a:hover { background: var(--accent-color); }

/* ------------------------------
   Contact
------------------------------ */
.contact .info-box {
  background: var(--accent-color); color: var(--contrast-color);
  padding: 2rem; border-radius: 1rem; height: 100%;
}
.contact .contact-form {
  background: var(--surface-color); color: var(--default-color);
  padding: 2rem; border-radius: 1rem;
  box-shadow: 0 0 25px rgba(0,0,0,.05);
}
.contact .form-control, .contact .form-select {
  padding: .875rem 1.25rem;
  border-color: color-mix(in srgb, var(--default-color), transparent 90%);
  border-radius: .5rem;
  background: color-mix(in srgb, var(--surface-color) 90%, white 5%);
  color: var(--default-color);
}
.contact .form-control:focus, .contact .form-select:focus {
  box-shadow: none; border-color: var(--accent-color);
}
.contact .btn {
  background: var(--accent-color); color: var(--contrast-color);
  padding: .9rem 1.8rem; border-radius: 2rem;
}

/* ------------------------------
   Footer
------------------------------ */
.footer {
  color: var(--default-color);
  background: var(--background-color);
  font-size: 14px;
  padding: 0 0 40px 0;
  position: relative;
}
.footer .copyright {
  padding-top: 40px;
  border-top: 1px solid color-mix(in srgb, var(--default-color), transparent 90%);
  text-align: center;
}
.footer .credits { margin-top: 4px; font-size: 13px; text-align: center; }

/* ------------------------------
   Small tweaks
------------------------------ */
@media (max-width: 991px) {
  .about .profile-card { margin-bottom: 2rem; }
}
