/* ============================================================
   ErisCom – Design System  (Bootstrap 5 + custom)
   ============================================================ */

/* ---------- CSS VARIABLES ---------- */
:root {
  --ec-dark:   #0e0e0e;
  --ec-dark2:  #161616;
  --ec-dark3:  #1e1e1e;
  --ec-gold:   #c9a84c;
  --ec-gold2:  #e8c97a;
  --ec-text:   #e8e4de;
  --ec-muted:  #8a8070;
  --ec-border: rgba(201,168,76,.18);
}

/* ---------- RESET / BASE ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--ec-dark);
  color: var(--ec-text);
  font-family: 'Outfit', sans-serif;
  font-weight: 300;
  overflow-x: hidden;
}

/* ---------- NAVBAR ---------- */
.navbar {
  background: transparent;
  padding: 1.4rem 2rem;
  transition: background .35s, backdrop-filter .35s;
  position: fixed; top:0; left:0; right:0; z-index:1000;
}
.navbar.scrolled {
  background: rgba(14,14,14,.92);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--ec-border);
}
.navbar-brand img { height: 42px; filter: brightness(1.1); }
.nav-link {
  color: var(--ec-text) !important;
  font-size: .82rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  font-weight: 400;
  padding: .4rem .9rem !important;
  transition: color .2s;
}
.nav-link:hover,
.nav-link.active { color: var(--ec-gold) !important; }
.navbar-toggler { border-color: var(--ec-border); }
.navbar-toggler-icon { filter: invert(1); }

.dropdown-menu {
  background: var(--ec-dark2);
  border: 1px solid var(--ec-border);
  border-radius: 0;
  min-width: 220px;
  padding: .5rem 0;
}
.dropdown-item {
  color: var(--ec-text);
  font-size: .8rem;
  letter-spacing: .06em;
  padding: .55rem 1.4rem;
  transition: background .15s, color .15s;
}
.dropdown-item:hover,
.dropdown-item:focus { background: var(--ec-border); color: var(--ec-gold); }

/* ---------- BUTTONS ---------- */
.btn-ec {
  background: var(--ec-gold);
  color: #0e0e0e;
  font-size: .78rem;
  letter-spacing: .15em;
  text-transform: uppercase;
  font-weight: 500;
  padding: .85rem 2.2rem;
  border: none;
  border-radius: 0;
  transition: background .2s, color .2s;
  text-decoration: none;
  display: inline-block;
  cursor: pointer;
}
.btn-ec:hover { background: var(--ec-gold2); color: #0e0e0e; }
.btn-ec-outline {
  border: 1px solid var(--ec-border);
  color: var(--ec-text);
  font-size: .78rem;
  letter-spacing: .15em;
  text-transform: uppercase;
  font-weight: 400;
  padding: .85rem 2.2rem;
  background: transparent;
  border-radius: 0;
  transition: border-color .2s, color .2s;
  text-decoration: none;
  display: inline-block;
}
.btn-ec-outline:hover { border-color: var(--ec-gold); color: var(--ec-gold); }

/* ---------- SECTION COMMON ---------- */
section { padding: 6rem 0; }
.sec-label {
  font-size: .72rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ec-gold);
  margin-bottom: .8rem;
}
.sec-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2rem, 4.5vw, 3.4rem);
  font-weight: 300;
  line-height: 1.15;
  color: var(--ec-text);
}
.sec-title em { font-style: italic; color: var(--ec-gold); }
.divider {
  width: 50px; height: 1px;
  background: var(--ec-gold);
  margin: 1.6rem 0;
}
.body-text { color: var(--ec-muted); line-height: 1.85; font-size: .95rem; }

/* ---------- HERO ---------- */
#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  background: var(--ec-dark);
}
.hero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(var(--ec-border) 1px, transparent 1px),
    linear-gradient(90deg, var(--ec-border) 1px, transparent 1px);
  background-size: 70px 70px;
  opacity: .5;
}
.hero-glow {
  position: absolute;
  top: -200px; right: -200px;
  width: 700px; height: 700px;
  background: radial-gradient(circle, rgba(201,168,76,.12) 0%, transparent 70%);
  pointer-events: none;
}
.hero-glow2 {
  position: absolute;
  bottom: -150px; left: -100px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(201,168,76,.07) 0%, transparent 70%);
  pointer-events: none;
}
.hero-content { position: relative; z-index: 2; padding-top: 100px; }
.hero-eyebrow {
  font-size: .75rem;
  letter-spacing: .25em;
  text-transform: uppercase;
  color: var(--ec-gold);
  margin-bottom: 1.4rem;
  display: flex; align-items: center; gap: .8rem;
}
.hero-eyebrow::after {
  content: '';
  display: inline-block;
  width: 40px; height: 1px;
  background: var(--ec-gold);
}
.hero-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(3rem, 8vw, 6.5rem);
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -.01em;
  color: var(--ec-text);
}
.hero-title em { font-style: italic; color: var(--ec-gold); }
.hero-sub {
  font-size: 1rem;
  color: var(--ec-muted);
  max-width: 520px;
  line-height: 1.75;
  margin: 1.8rem 0 2.4rem;
}

/* tags */
.tag-list { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 2.5rem; }
.tag {
  font-size: .7rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ec-muted);
  border: 1px solid var(--ec-border);
  padding: .3rem .9rem;
  transition: color .2s, border-color .2s;
}
.tag:hover { color: var(--ec-gold); border-color: var(--ec-gold); cursor: default; }

/* ---------- ABOUT ---------- */
#about { background: var(--ec-dark2); }
.about-card {
  border: 1px solid var(--ec-border);
  padding: 2.2rem 2rem;
  background: var(--ec-dark3);
  transition: border-color .25s, transform .25s;
  height: 100%;
}
.about-card:hover { border-color: rgba(201,168,76,.5); transform: translateY(-3px); }
.about-card-icon { font-size: 1.8rem; color: var(--ec-gold); margin-bottom: 1.2rem; }
.about-card h5 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--ec-text);
  margin-bottom: .6rem;
}

/* ---------- SERVICES ---------- */
#services { background: var(--ec-dark); }
.service-item {
  border-top: 1px solid var(--ec-border);
  padding: 1.6rem 0;
  display: flex;
  align-items: flex-start;
  gap: 1.4rem;
  cursor: default;
}
.service-item:last-child { border-bottom: 1px solid var(--ec-border); }
.service-item:hover .service-num { color: var(--ec-gold2); }
.service-item:hover .service-title { color: var(--ec-gold); }
.service-num {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.1rem;
  color: var(--ec-border);
  min-width: 36px;
  padding-top: .2rem;
  transition: color .2s;
}
.service-title {
  font-size: 1rem;
  font-weight: 500;
  color: var(--ec-text);
  margin-bottom: .3rem;
  transition: color .2s;
  letter-spacing: .03em;
}
.service-desc { font-size: .85rem; color: var(--ec-muted); line-height: 1.6; }
.service-icon {
  font-size: 1.1rem;
  color: var(--ec-muted);
  margin-left: auto;
  padding-top: .2rem;
  text-decoration: none;
  transition: color .2s;
}
.service-icon:hover { color: var(--ec-gold); }

/* ---------- QUOTE ---------- */
#quote {
  background: var(--ec-dark2);
  border-top: 1px solid var(--ec-border);
  border-bottom: 1px solid var(--ec-border);
  padding: 5rem 0;
}
.quote-carousel .blockquote {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.5rem, 3.5vw, 2.4rem);
  font-weight: 300;
  font-style: italic;
  line-height: 1.4;
  color: var(--ec-text);
  text-align: center;
  max-width: 820px;
  margin: 0 auto;
}
.blockquote-footer {
  color: var(--ec-gold) !important;
  font-size: .82rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  margin-top: 1.2rem;
  text-align: center;
}
.blockquote-footer::before { display: none; }

/* ---------- STATS ---------- */
#stats { background: var(--ec-dark); padding: 4rem 0; }
.stat-num {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(3rem, 6vw, 4.5rem);
  font-weight: 300;
  color: var(--ec-gold);
  line-height: 1;
}
.stat-label {
  font-size: .75rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ec-muted);
  margin-top: .5rem;
}

/* ---------- WHY ---------- */
#why { background: var(--ec-dark2); }
.why-item {
  display: flex; gap: 1.2rem;
  padding: 1.6rem;
  border: 1px solid transparent;
  transition: border-color .25s;
}
.why-item:hover { border-color: var(--ec-border); }
.why-num {
  font-family: 'Cormorant Garamond', serif;
  font-size: 3rem;
  font-weight: 300;
  color: var(--ec-border);
  line-height: 1;
  min-width: 48px;
  transition: color .2s;
}
.why-item:hover .why-num { color: rgba(201,168,76,.35); }
.why-text { font-size: .9rem; color: var(--ec-muted); line-height: 1.7; padding-top: .5rem; }

/* ---------- CONTACT ---------- */
#contact { background: var(--ec-dark); }
.contact-form-wrap {
  background: var(--ec-dark2);
  border: 1px solid var(--ec-border);
  padding: 3rem;
}
.form-label {
  font-size: .72rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ec-muted);
  margin-bottom: .4rem;
}
.form-control, .form-select {
  background: var(--ec-dark3) !important;
  border: 1px solid var(--ec-border) !important;
  border-radius: 0 !important;
  color: var(--ec-text) !important;
  font-size: .9rem;
  padding: .75rem 1rem;
}
.form-control:focus, .form-select:focus {
  box-shadow: none !important;
  border-color: rgba(201,168,76,.5) !important;
}
.form-control::placeholder { color: var(--ec-muted); }
textarea.form-control { resize: none; min-height: 130px; }
.contact-info-block { border-left: 1px solid var(--ec-border); padding-left: 2.5rem; }
.ci-row { display: flex; gap: 1rem; align-items: flex-start; margin-bottom: 1.8rem; }
.ci-icon { font-size: 1.1rem; color: var(--ec-gold); margin-top: .15rem; flex-shrink: 0; }
.ci-label { font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ec-muted); margin-bottom: .2rem; }
.ci-val { font-size: .95rem; color: var(--ec-text); }

/* alert feedback messages */
.alert-success {
  background: rgba(201,168,76,.12);
  border: 1px solid var(--ec-gold);
  color: var(--ec-gold2);
  border-radius: 0;
}
.alert-danger {
  background: rgba(220,53,69,.12);
  border: 1px solid rgba(220,53,69,.4);
  color: #f8a4ac;
  border-radius: 0;
}
.alert-info {
  background: rgba(201,168,76,.08);
  border: 1px solid var(--ec-border);
  color: var(--ec-muted);
  border-radius: 0;
}

/* ---------- FOOTER ---------- */
footer {
  background: var(--ec-dark2);
  border-top: 1px solid var(--ec-border);
  padding: 3.5rem 0 2rem;
}
.footer-logo img { height: 36px; filter: brightness(1.1); margin-bottom: 1rem; }
.footer-tagline { font-size: .8rem; color: var(--ec-muted); letter-spacing: .06em; }
.footer-links a {
  color: var(--ec-muted);
  text-decoration: none;
  font-size: .8rem;
  letter-spacing: .06em;
  display: block;
  margin-bottom: .4rem;
  transition: color .2s;
}
.footer-links a:hover { color: var(--ec-gold); }
.footer-heading {
  font-size: .7rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ec-gold);
  margin-bottom: 1rem;
}
.footer-bottom {
  border-top: 1px solid var(--ec-border);
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  font-size: .72rem;
  color: var(--ec-muted);
  letter-spacing: .06em;
}
.social-links a {
  color: var(--ec-muted);
  font-size: 1.15rem;
  margin-right: .9rem;
  transition: color .2s;
  text-decoration: none;
}
.social-links a:hover { color: var(--ec-gold); }

/* ---------- SUBPAGE HERO (_PLayout) ---------- */
.subpage-hero {
  min-height: 420px;
  display: flex;
  align-items: flex-end;
  position: relative;
  overflow: hidden;
  background-size: cover;
  background-position: center top;
  padding-top: 80px;
}
.subpage-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, rgba(14,14,14,.45) 0%, rgba(14,14,14,.85) 100%);
}
.subpage-hero-content {
  position: relative; z-index: 2;
  padding-bottom: 3rem;
}
.subpage-hero h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2rem, 5vw, 3.8rem);
  font-weight: 300;
  color: var(--ec-text);
  line-height: 1.1;
}
.subpage-hero h1 span { color: var(--ec-gold); font-style: italic; }

/* ---------- BREADCRUMB ---------- */
.breadcrumb {
  background: transparent;
  padding: 0;
  margin: 0;
}
.breadcrumb-item a { color: var(--ec-muted); text-decoration: none; font-size: .8rem; }
.breadcrumb-item a:hover { color: var(--ec-gold); }
.breadcrumb-item.active { color: var(--ec-muted); font-size: .8rem; }
.breadcrumb-item + .breadcrumb-item::before { color: var(--ec-border); }

/* ---------- PORTFOLIO MASONRY (Fotografia/Grafica) ---------- */
.portfolio-masonary {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 0 4px;
}
.portfolio-masonary-col {
  flex: 1 1 280px;
  min-width: 200px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.portfolio-masonary-col.w2 { flex: 2 1 500px; flex-direction: row; flex-wrap: wrap; }
.portfolio-masonary-col.w2 .portfolio-item { flex: 1 1 220px; }
.portfolio-item {
  position: relative;
  overflow: hidden;
  cursor: pointer;
}
.portfolio-item img {
  width: 100%;
  display: block;
  object-fit: cover;
  min-height: 240px;
  transition: transform .5s;
}
.portfolio-item:hover img { transform: scale(1.04); }
.portfolio-item-content {
  position: absolute; inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.4rem;
  opacity: 0;
  transition: opacity .35s;
  background: linear-gradient(to top, rgba(14,14,14,.85) 0%, transparent 60%) !important;
}
.portfolio-item:hover .portfolio-item-content { opacity: 1; }
.portfolio-item-content h3,
.portfolio-item-content h4 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.3rem;
  color: var(--ec-text);
  font-weight: 300;
  margin-bottom: .3rem;
}
.portfolio-item-content p {
  font-size: .78rem;
  color: var(--ec-muted);
  margin: 0;
  line-height: 1.5;
}
.portfolio-item-content a {
  color: var(--ec-gold2);
  text-decoration: none;
}

/* ---------- INNER PAGES (SitiWeb, Settori) ---------- */
.inner-section { background: var(--ec-dark2); }
.inner-section + .inner-section { background: var(--ec-dark); }

.blog-inner h1, .blog-inner h2, .blog-inner h3 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 300;
  color: var(--ec-text);
}
.blog-inner h1 span,
.blog-inner h2 span { color: var(--ec-gold); }

.sidebar-widget {
  background: var(--ec-dark3);
  border: 1px solid var(--ec-border);
  padding: 1.8rem;
  margin-bottom: 1.6rem;
}
.sidebar-widget h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.2rem;
  color: var(--ec-gold);
  margin-bottom: 1rem;
}
.sidebar-widget ul { padding-left: 1rem; }
.sidebar-widget ul li { margin-bottom: .5rem; }
.sidebar-widget ul li a { color: var(--ec-muted); text-decoration: none; font-size: .85rem; transition: color .2s; }
.sidebar-widget ul li a:hover { color: var(--ec-gold); }

/* ---------- BLOG ---------- */
.blog-card {
  background: var(--ec-dark2);
  border: 1px solid var(--ec-border);
  transition: border-color .25s, transform .25s;
  overflow: hidden;
  height: 100%;
}
.blog-card:hover { border-color: rgba(201,168,76,.45); transform: translateY(-3px); }
.blog-card-img { width: 100%; height: 200px; object-fit: cover; display: block; }
.blog-card-body { padding: 1.4rem; }
.blog-card-cat {
  font-size: .68rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ec-gold);
  margin-bottom: .5rem;
}
.blog-card-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.3rem;
  font-weight: 300;
  color: var(--ec-text);
  margin-bottom: .5rem;
  text-decoration: none;
  display: block;
  transition: color .2s;
}
.blog-card-title:hover { color: var(--ec-gold); }
.blog-card-summary { font-size: .85rem; color: var(--ec-muted); line-height: 1.65; }
.blog-card-meta { font-size: .72rem; color: var(--ec-muted); margin-top: .8rem; }

.blog-filter-select {
  background: var(--ec-dark3) !important;
  border: 1px solid var(--ec-border) !important;
  border-radius: 0 !important;
  color: var(--ec-text) !important;
  font-size: .85rem;
  padding: .6rem 1rem;
  max-width: 360px;
}

/* blog detail */
.blog-detail-content {
  color: var(--ec-muted);
  line-height: 1.9;
  font-size: .95rem;
  white-space: pre-wrap;
}
.blog-detail-content p { margin-bottom: 1rem; }

/* ---------- BACK TO TOP ---------- */
#back-to-top {
  position: fixed;
  bottom: 2rem; right: 1.8rem;
  width: 40px; height: 40px;
  background: var(--ec-dark2);
  border: 1px solid var(--ec-border);
  color: var(--ec-gold);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s;
  text-decoration: none;
  z-index: 900;
}
#back-to-top.visible { opacity: 1; pointer-events: auto; }

/* ---------- SCROLL ANIMATIONS ---------- */
.fade-up {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .6s ease, transform .6s ease;
}
.fade-up.visible { opacity: 1; transform: translateY(0); }
.fade-up.d1 { transition-delay: .1s; }
.fade-up.d2 { transition-delay: .2s; }
.fade-up.d3 { transition-delay: .3s; }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 991px) {
  .navbar { padding: 1rem 1.2rem; }
  .dropdown-menu { border-radius: 0; }
}
@media (max-width: 768px) {
  section { padding: 4rem 0; }
  .contact-info-block {
    border-left: none;
    border-top: 1px solid var(--ec-border);
    padding-left: 0;
    padding-top: 2rem;
    margin-top: 2rem;
  }
  .contact-form-wrap { padding: 1.8rem 1.2rem; }
  .subpage-hero { min-height: 280px; }
}
