@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700&display=swap');
:root {
  --bg: #111;
  --fg: #fff;
  --accent: #222;
  --gray: #888;
  --primary: #fff;
  --secondary: #222;
  --border: #333;
  --glow: 0 0 16px #fff8, 0 0 32px #fff4;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: 'Montserrat', Arial, sans-serif;
  background: var(--bg);
  color: var(--fg);
  min-height: 100vh;
  line-height: 1.6;
  overflow-x: hidden;
}
html { }
main { overflow-x: hidden; }
header {
  padding: 40px 0 20px 0;
  text-align: center;
  background: var(--bg);
  opacity: 0;
  transform: translateY(-30px);
  animation: fadeInDown 1.1s 0.2s cubic-bezier(.4,1.4,.6,1) forwards;
  position: relative;
}
@keyframes fadeInDown {
  to { opacity: 1; transform: none; }
}
.logo {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  background: linear-gradient(90deg, #fff 0%, #fff 20%, #e0e0e0 40%, #bdbdbd 60%, #fff 80%, #fff 100%);
  background-size: 300% auto;
  color: transparent;
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: logoAppear 1.2s 0.5s cubic-bezier(.4,1.4,.6,1) forwards, logo-gradient-move 2s linear infinite;
  opacity: 0;
  transform: scale(0.95);
}
@keyframes logoAppear {
  to { opacity: 1; transform: none; }
}
@keyframes logo-gradient-move {
  0% {
    background-position: 0% 50%;
  }
  100% {
    background-position: 300% 50%;
  }
}
.logo-sub {
  font-size: 0.98em;
  font-weight: 400;
  color: #bdbdbd;
  letter-spacing: 0.01em;
  margin-bottom: 8px;
  margin-top: -8px;
  text-align: center;
  font-family: inherit;
  user-select: none;
}
nav {
  margin: 30px 0 0 0;
  opacity: 0;
  transform: translateY(-10px);
  animation: fadeInNav 1.2s 0.8s cubic-bezier(.4,1.4,.6,1) forwards;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 24px;
}
@keyframes fadeInNav {
  to { opacity: 1; transform: none; }
}
nav a {
  color: var(--fg);
  text-decoration: none;
  margin: 0 18px;
  font-weight: 500;
  font-size: 1.1rem;
  transition: color 0.2s, text-shadow 0.2s, transform 0.2s;
  position: relative;
}
nav a:hover {
  color: var(--gray);
  text-shadow: 0 0 8px #fff3;
  transform: scale(1.08);
}
.lang-switcher {
  display: flex;
  gap: 8px;
  margin-left: 32px;
  align-items: center;
}
.lang-btn {
  background: transparent;
  color: var(--fg);
  border: none;
  border-radius: 6px;
  padding: 4px 13px;
  font-size: 1rem;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
  outline: none;
  box-shadow: none;
  letter-spacing: 0.04em;
}
.lang-btn:hover {
  background: #222;
  color: #fff;
}
.lang-btn.active {
  background: #fff;
  color: #111;
  box-shadow: 0 0 8px #fff4;
}
.auth-btn {
  background: #fff;
  color: #111;
  border: none;
  border-radius: 6px;
  padding: 4px 16px;
  font-size: 1rem;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  margin-left: 8px;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
  box-shadow: 0 0 8px #fff2;
  outline: none;
  display: inline-block;
}
.auth-btn:hover {
  background: #222;
  color: #fff;
  box-shadow: 0 0 12px #fff4;
}
.login-btn {
  background: #fff;
  color: #111;
}
.register-btn {
  background: #2196f3;
  color: #fff;
}
.register-btn:hover {
  background: #1565c0;
  color: #fff;
}
main {
  max-width: 900px;
  margin: 40px auto 0 auto;
  padding: 0 20px 40px 20px;
}
section {
  margin-bottom: 60px;
  background: var(--secondary);
  border-radius: 18px;
  padding: 36px 28px;
  box-shadow: 0 2px 16px 0 rgba(0,0,0,0.08);
  border: 1px solid var(--border);
  opacity: 0;
  transform: translateY(40px) scale(0.98);
  transition: opacity 0.8s cubic-bezier(.4,1.4,.6,1), transform 0.8s cubic-bezier(.4,1.4,.6,1);
}
section.visible {
  opacity: 1;
  transform: none;
}
.hero h1 {
  font-size: 2.2rem;
  font-weight: 700;
  margin-bottom: 18px;
}
.hero p {
  font-size: 1.2rem;
  color: var(--gray);
  margin-bottom: 24px;
}
.features {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-bottom: 18px;
}
.feature {
  background: #181818;
  border-radius: 10px;
  padding: 16px 18px;
  flex: 1 1 220px;
  color: var(--fg);
  font-size: 1rem;
  border: 1px solid var(--border);
  transition: box-shadow 0.25s, transform 0.25s;
  box-shadow: 0 2px 8px 0 #0002;
}
.feature:hover {
  box-shadow: 0 4px 24px 0 #fff2, 0 2px 16px 0 #0004;
  transform: scale(1.04) translateY(-2px);
  z-index: 1;
}
.cta-btn {
  display: inline-block;
  background: var(--fg);
  color: var(--bg);
  font-weight: 700;
  padding: 14px 36px;
  border-radius: 8px;
  font-size: 1.1rem;
  text-decoration: none;
  margin-top: 18px;
  transition: background 0.2s, color 0.2s, box-shadow 0.3s;
  box-shadow: var(--glow);
  animation: ctaGlow 2.5s infinite alternate;
}
@keyframes ctaGlow {
  from { box-shadow: 0 0 8px #fff4, 0 0 0 #fff0; }
  to { box-shadow: 0 0 24px #fff8, 0 0 32px #fff4; }
}
.cta-btn:hover {
  background: var(--gray);
  color: var(--fg);
  box-shadow: 0 0 32px #fff8, 0 0 64px #fff4;
  transform: scale(1.04);
}
.about h2, .consult h2, .contacts h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 16px;
}
.about {
  position: relative;
  overflow: hidden;
}
.about .about-bg {
  position: absolute;
  inset: -10%;
  pointer-events: none;
  background: radial-gradient(600px 220px at 20% 0%, rgba(33,150,243,0.08), transparent 60%),
              radial-gradient(500px 200px at 80% 10%, rgba(79,195,247,0.06), transparent 65%);
  filter: blur(0px) saturate(110%);
  animation: aboutFloat 18s ease-in-out infinite alternate;
  z-index: 0;
}
@keyframes aboutFloat { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(0, 8px, 0); } }
.about > *:not(.about-bg) { position: relative; z-index: 1; }
.about p {
  color: var(--gray);
  font-size: 1.1rem;
}
.about-mission {
  position: relative;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .6s ease, transform .6s ease;
}
.about.visible .about-mission { opacity: 1; transform: none; }
.consult form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 10px;
}
.consult input, .consult textarea {
  background: #181818;
  color: var(--fg);
  border: 1px solid var(--border);
  border-radius: 7px;
  padding: 12px;
  font-size: 1rem;
  resize: none;
  transition: box-shadow 0.2s, border 0.2s;
}
.consult input:focus, .consult textarea:focus {
  outline: 2px solid var(--gray);
  box-shadow: 0 0 8px #fff4;
  border: 1.5px solid #fff;
}
.consult button {
  background: var(--fg);
  color: var(--bg);
  font-weight: 700;
  border: none;
  border-radius: 7px;
  padding: 12px;
  font-size: 1.1rem;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
  box-shadow: 0 0 8px #fff4;
}
.consult button:hover {
  background: var(--gray);
  color: var(--fg);
  box-shadow: 0 0 24px #fff8;
  transform: scale(1.03);
}
.contacts ul {
  list-style: none;
  padding: 0;
}
.contacts li {
  margin-bottom: 10px;
  font-size: 1.1rem;
}
.contacts a {
  color: var(--fg);
  text-decoration: underline;
  word-break: break-all;
  transition: color 0.2s, text-shadow 0.2s;
}
.contacts a:hover {
  color: #fff;
  text-shadow: 0 0 8px #fff4;
}
.contact-form { background:#1f1f24; border:1px solid var(--border); border-radius: 18px; padding: 18px; box-shadow: 0 2px 16px rgba(0,0,0,.08); margin-top: 16px; }
.contact-form .cf-grid { display:grid; grid-template-columns: repeat(3, minmax(180px,1fr)); gap: 18px; }
.contact-form label { position:relative; display:flex; flex-direction:column; gap:6px; color:#e0e0e0; padding-top: 12px; }
.contact-form label span { position:absolute; left:14px; top:14px; color:#bdbdbd; font-size: .95rem; line-height:1; padding: 0 6px; border-radius: 6px; background:#1f1f24; transform-origin: left top; transition: transform .2s ease, color .2s ease, opacity .2s ease, background .2s ease; pointer-events:none; }
.contact-form input, .contact-form textarea { background:#232428; color:#fff; border:1px solid #2b2b2b; border-radius:12px; padding:18px 14px 12px 14px; outline:none; transition:border-color .2s, box-shadow .2s, background .2s, transform .2s; }
.contact-form input::placeholder, .contact-form textarea::placeholder { color: transparent; }
.contact-form input:hover, .contact-form textarea:hover { border-color:#3a3a3a; }
.contact-form input:focus, .contact-form textarea:focus { border-color:#2196f3; box-shadow: 0 0 0 3px rgba(33,150,243,.12); background:#25272c; }
/* span before input — move on focus/filled using :focus-within and :has */
.contact-form label:focus-within span { transform: translateY(-12px) scale(0.86); color:#4fc3f7; }
.contact-form label:has(input:not(:placeholder-shown)) span,
.contact-form label:has(textarea:not(:placeholder-shown)) span,
.contact-form label.is-filled span { transform: translateY(-12px) scale(0.86); color:#9ecff0; }
.contact-form .cf-full { grid-column: 1 / -1; }
.contact-form .cf-actions { margin-top: 8px; display:flex; align-items:center; gap:14px; }
.contact-form .cf-status { color:#bdbdbd; font-size:.95rem; }
@media (max-width: 900px){ .contact-form .cf-grid { grid-template-columns: 1fr; } }

/* Micro-interactions */
.contact-form .cta-btn { position: relative; overflow: hidden; transition: transform .15s ease, box-shadow .2s ease; }
.contact-form .cta-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 22px rgba(33,150,243,.22); }
.contact-form .cta-btn:active { transform: translateY(0); box-shadow: 0 2px 10px rgba(33,150,243,.18); }

/* Contact success card */
.contact-success { background:#1f1f24; border:1px solid var(--border); border-radius:18px; padding:26px; text-align:center; box-shadow: 0 2px 16px rgba(0,0,0,.08); }
.cs-check { display:inline-flex; align-items:center; justify-content:center; width:84px; height:84px; margin:0 auto 10px auto; background:#1b1b20; border-radius:50%; border:1px solid #2b2b2b; box-shadow: inset 0 0 0 1px rgba(255,255,255,.04); }
.cs-svg { width:56px; height:56px; }
.cs-circle { stroke:#2e7d32; stroke-width:2; opacity:.35; }
.cs-path { stroke:#66bb6a; stroke-width:4; stroke-linecap:round; stroke-linejoin:round; stroke-dasharray:60; stroke-dashoffset:60; animation: cs-draw .9s .15s ease forwards; }
.cs-check { animation: cs-pop .6s ease forwards; transform: scale(.9); opacity: 0; }
.cs-check--static { opacity:1; transform:none; animation:none; }
.cs-path--done { stroke-dashoffset:0; animation:none; }
.cs-title { font-size:1.2rem; font-weight:700; color:#fff; margin-top:4px; }
.cs-sub { color:#bdbdbd; margin-top:6px; }
@keyframes cs-draw { to { stroke-dashoffset: 0; } }
@keyframes cs-pop { to { transform: scale(1); opacity:1; } }
.burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 38px;
  height: 38px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 1002;
  margin-left: auto;
}
.burger span {
  display: block;
  width: 26px;
  height: 3.5px;
  background: var(--fg);
  margin: 4px 0;
  border-radius: 2px;
  transition: 0.3s;
}
.burger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.burger.open span:nth-child(2) {
  opacity: 0;
}
.burger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}
@media (max-width: 700px) {
  main { padding: 0 4vw 40px 4vw; }
  section { padding: 24px 8px; }
  .features {
    display: block;
  }
  .logo { font-size: 2rem; }
  .hero h1 { font-size: 1.3rem; }
  .hero p { font-size: 1rem; }
  .feature {
    display: block;
    width: 100%;
    min-width: 0;
    max-width: 100%;
    flex: none;
    height: auto;
    margin-bottom: 10px;
    font-size: 0.95rem;
    padding: 10px 10px;
    border-radius: 7px;
  }
  .burger {
    display: flex;
    position: absolute;
    top: 38px;
    right: 18px;
  }
  nav.nav-menu {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(17,17,17,0.98);
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 24px;
    z-index: 1001;
    transform: translateY(-100%) !important;
    opacity: 0 !important;
    pointer-events: none !important;
    transition: transform 0.35s cubic-bezier(.4,1.4,.6,1), opacity 0.25s;
    height: 100vh;
    width: 100vw;
    box-shadow: 0 8px 32px #0008;
    padding-left: 0;
  }
  nav.nav-menu.open {
    transform: none !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }
  nav.nav-menu a {
    font-size: 1.08rem;
    margin: 0;
    padding: 10px 0 10px 22px;
    display: block;
    text-align: left;
    border-radius: 7px;
    transition: background 0.18s, color 0.18s;
  }
  nav.nav-menu a:hover {
    background: #232323;
    color: #fff;
  }
  .lang-switcher {
    margin-left: 0;
    justify-content: flex-start;
    margin-top: 18px;
    flex-wrap: wrap;
    padding-left: 18px;
  }
  .auth-btn {
    font-size: 0.98rem;
    padding: 6px 14px;
    margin-left: 0;
    margin-top: 8px;
    border-radius: 8px;
    box-shadow: 0 0 8px #2196f344;
    transition: background 0.18s, color 0.18s, box-shadow 0.18s;
    display: inline-block;
  }
  .auth-btn.login-btn {
    background: #fff;
    color: #111;
  }
  .auth-btn.register-btn {
    background: #2196f3;
    color: #fff;
  }
  .auth-btn:hover {
    background: #232323;
    color: #fff;
  }
  body.nav-open {
    overflow: hidden;
  }
}

/* FAQ Section */
.faq {
  margin-bottom: 40px;
  background: var(--secondary);
  border-radius: 18px;
  padding: 36px 28px;
  box-shadow: 0 2px 16px 0 rgba(0,0,0,0.08);
  border: 1px solid var(--border);
}
.faq h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 18px;
}
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.faq-item {
  border-radius: 10px;
  background: #181818;
  border: 1px solid var(--border);
  overflow: hidden;
  transition: box-shadow 0.2s;
}
.faq-item.open {
  box-shadow: 0 4px 24px 0 #fff2, 0 2px 16px 0 #0004;
}
.faq-question {
  width: 100%;
  background: none;
  color: var(--fg);
  border: none;
  text-align: left;
  font-size: 1.08rem;
  font-weight: 600;
  padding: 18px 16px;
  cursor: pointer;
  outline: none;
  transition: background 0.18s, color 0.18s;
  position: relative;
}
.faq-question::after {
  content: '+';
  position: absolute;
  right: 18px;
  font-size: 1.2em;
  transition: transform 0.3s;
}
.faq-item.open .faq-question::after {
  content: '-';
  transform: rotate(180deg);
}
.faq-answer {
  max-height: 0;
  overflow: hidden;
  background: #202020;
  color: var(--gray);
  font-size: 1rem;
  padding: 0 16px;
  transition: max-height 0.35s cubic-bezier(.4,1.4,.6,1), padding 0.25s;
}
.faq-item.open .faq-answer {
  padding: 14px 16px 18px 16px;
  max-height: 300px;
}
@media (max-width: 700px) {
  .faq { padding: 18px 4px; }
  .faq-question { font-size: 1rem; padding: 12px 10px; }
  .faq-answer { font-size: 0.97rem; padding: 0 10px; }
  .faq-item.open .faq-answer { padding: 10px 10px 14px 10px; }
}

body, html {
  position: relative;
  z-index: 1;
  background: #111;
}
main, header, .faq, .consult, .about, .hero, .contacts {
  position: static;
}

/* Кейсы (портфолио) */
.cases {
  margin-bottom: 60px;
  background: var(--secondary);
  border-radius: 18px;
  padding: 36px 28px;
  box-shadow: 0 2px 16px 0 rgba(0,0,0,0.08);
  border: 1px solid var(--border);
}
.cases h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 18px;
}
.cases-list {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}
.case-card {
  background: #181818;
  border-radius: 12px;
  border: 1px solid var(--border);
  box-shadow: 0 2px 8px 0 #0002;
  padding: 22px 18px 16px 18px;
  flex: 1 1 340px;
  min-width: 300px;
  max-width: 400px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
}
.case-image {
  width: 100%;
  border-radius: 8px;
  margin-bottom: 10px;
  object-fit: cover;
  background: #222;
}
.case-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 6px 0 2px 0;
}
.case-desc {
  color: var(--gray);
  font-size: 1rem;
  margin-bottom: 8px;
}
.case-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 8px;
  flex-wrap: wrap;
}
.like-btn, .share-btn, .download-btn {
  background: #232323;
  color: var(--fg);
  border: none;
  border-radius: 6px;
  padding: 7px 14px;
  font-size: 1rem;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
  outline: none;
  box-shadow: none;
  display: flex;
  align-items: center;
  gap: 4px;
}
.like-btn:hover, .share-btn:hover, .download-btn:hover {
  background: #fff;
  color: #111;
  box-shadow: 0 0 8px #fff4;
}
.download-btn[disabled] {
  opacity: 0.5;
  pointer-events: none;
}
.comments {
  margin-top: 8px;
  background: #202020;
  border-radius: 7px;
  padding: 10px 10px 6px 10px;
}
.comment {
  color: var(--gray);
  font-size: 0.98rem;
  margin-bottom: 6px;
}
.add-comment {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}
.add-comment input[type="text"] {
  flex: 1;
  background: #181818;
  color: var(--fg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 7px 10px;
  font-size: 0.98rem;
}
.add-comment button {
  background: var(--fg);
  color: var(--bg);
  border: none;
  border-radius: 6px;
  padding: 7px 14px;
  font-size: 0.98rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
}
.add-comment button:hover {
  background: var(--gray);
  color: var(--fg);
  box-shadow: 0 0 8px #fff4;
}
@media (max-width: 700px) {
  .cases { padding: 18px 4px; }
  .cases-list { flex-direction: column; gap: 14px; }
  .case-card { max-width: 100%; min-width: 0; padding: 12px 6px 10px 6px; }
  .case-title { font-size: 1.05rem; }
  .case-desc { font-size: 0.97rem; }
}

/* --- AUTH PAGES (login, register) --- */
.auth-main {
  max-width: 420px;
  margin: 60px auto;
  background: #181818;
  border-radius: 18px;
  padding: 38px 28px 32px 28px;
  box-shadow: 0 4px 32px #0008, 0 2px 16px #0004;
  border: 1.5px solid #333;
  animation: fadeInAuth 1.1s cubic-bezier(.4,1.4,.6,1);
  position: relative;
}
@keyframes fadeInAuth {
  from { opacity: 0; transform: translateY(40px) scale(0.98); }
  to { opacity: 1; transform: none; }
}
.auth-logo {
  text-align: center;
  font-size: 2.1rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  margin-bottom: 18px;
  color: #fff;
  background: linear-gradient(90deg, #fff 0%, #e0e0e0 40%, #bdbdbd 60%, #fff 100%);
  background-size: 300% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: logo-gradient-move 2s linear infinite;
}
.auth-main h2 {
  text-align: center;
  margin-bottom: 22px;
  font-size: 1.35rem;
  font-weight: 700;
}
.auth-main form label {
  font-size: 1rem;
  color: #fff;
  margin-bottom: 2px;
  margin-top: 8px;
  display: block;
}
.auth-main input[type="email"],
.auth-main input[type="password"],
.auth-main input[type="text"] {
  width: 100%;
  background: #232323;
  color: #fff;
  border: 1.5px solid #333;
  border-radius: 7px;
  padding: 12px;
  font-size: 1rem;
  margin-bottom: 12px;
  transition: box-shadow 0.2s, border 0.2s;
}
.auth-main input:focus {
  outline: 2px solid #2196f3;
  box-shadow: 0 0 8px #2196f344;
  border: 1.5px solid #2196f3;
}
.auth-main button[type="submit"] {
  background: #2196f3;
  color: #fff;
  font-weight: 700;
  border: none;
  border-radius: 7px;
  padding: 12px;
  font-size: 1.1rem;
  cursor: pointer;
  width: 100%;
  margin-top: 10px;
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
  box-shadow: 0 0 8px #2196f344;
}
.auth-main button[type="submit"]:hover {
  background: #1565c0;
  color: #fff;
  box-shadow: 0 0 24px #2196f388;
  transform: scale(1.03);
}
.auth-main .auth-links {
  margin-top: 18px;
  text-align: center;
}
.auth-main .auth-links a {
  color: #2196f3;
  text-decoration: underline;
  font-size: 1.01em;
  margin: 0 6px;
  transition: color 0.18s;
}
.auth-main .auth-links a:hover {
  color: #fff;
}
@media (max-width: 700px) {
  .auth-main { padding: 18px 4vw 18px 4vw; }
  .auth-logo { font-size: 1.3rem; }
}

/* === Radius override for main page blocks === */
section,
.faq,
.cases,
.services,
.about-why,
.about-feature,
.services-list li,
.case-card,
.team3d__wrap {
  border-radius: 5px !important;
}

/* --- CASES (portfolio) --- */
.cases-list {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  justify-content: flex-start;
}
.case-card {
  background: #202020;
  border-radius: 14px;
  border: 1.5px solid #333;
  box-shadow: 0 4px 24px 0 #0006, 0 2px 8px 0 #0002;
  padding: 26px 18px 18px 18px;
  flex: 1 1 340px;
  min-width: 300px;
  max-width: 400px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  transition: box-shadow 0.25s, transform 0.25s;
}
.case-card:hover {
  box-shadow: 0 8px 32px 0 #2196f344, 0 2px 16px 0 #0004;
  transform: scale(1.025) translateY(-2px);
  z-index: 2;
}
.case-image {
  width: 100%;
  border-radius: 8px;
  margin-bottom: 10px;
  object-fit: cover;
  background: #222;
  box-shadow: 0 2px 8px #0004;
}
.case-title {
  font-size: 1.18rem;
  font-weight: 700;
  margin: 6px 0 2px 0;
  color: #fff;
}
.case-desc {
  color: #bdbdbd;
  font-size: 1.01rem;
  margin-bottom: 8px;
}
.case-actions {
  display: flex;
  gap: 14px;
  align-items: center;
  margin-bottom: 8px;
}
.like-btn, .share-btn, .download-btn {
  background: #232323;
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 7px 16px 7px 32px;
  font-size: 1rem;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
  outline: none;
  box-shadow: none;
  display: flex;
  align-items: center;
  gap: 4px;
  position: relative;
}
.like-btn::before, .share-btn::before, .download-btn::before {
  display: none !important;
  content: none !important;
}
.like-btn:hover, .share-btn:hover, .download-btn:hover {
  background: #2196f3;
  color: #fff;
  box-shadow: 0 0 8px #2196f344;
}
.download-btn[disabled] {
  opacity: 0.5;
  pointer-events: none;
}
.comments {
  margin-top: 8px;
  background: #232323;
  border-radius: 7px;
  padding: 10px 10px 6px 10px;
}
.comment {
  color: #bdbdbd;
  font-size: 0.98rem;
  margin-bottom: 6px;
}
.add-comment {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}
.add-comment input[type="text"] {
  flex: 1;
  background: #181818;
  color: var(--fg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 7px 10px;
  font-size: 0.98rem;
}
.add-comment button {
  background: #2196f3;
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 7px 14px;
  font-size: 0.98rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
}
.add-comment button:hover {
  background: #1565c0;
  color: #fff;
  box-shadow: 0 0 8px #2196f344;
}
@media (max-width: 700px) {
  .cases-list { flex-direction: column; gap: 14px; }
  .case-card { max-width: 100%; min-width: 0; padding: 12px 6px 10px 6px; }
  .case-title { font-size: 1.05rem; }
  .case-desc { font-size: 0.97rem; }
}

.profile-avatar-link {
  display: flex;
  align-items: center;
  margin-left: 12px;
}
.profile-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #2196f3;
  box-shadow: 0 2px 8px #0003;
  background: #fff;
  transition: box-shadow 0.18s, border 0.18s, transform 0.18s;
}
.profile-avatar-link:hover .profile-avatar {
  box-shadow: 0 4px 16px #2196f344;
  border: 2.5px solid #1565c0;
  transform: scale(1.07);
}
@media (max-width: 700px) {
  .profile-avatar {
    width: 32px;
    height: 32px;
  }
  .profile-avatar-link { margin-left: 0; }
}

.views-count {
  display: flex;
  align-items: center;
  gap: 5px;
  color: #888;
  font-size: 0.98em;
  margin-left: 0;
  position: relative;
}

.like-btn svg,
.share-btn svg,
.views-count svg {
  width: 18px;
  height: 18px;
  display: inline-block;
  vertical-align: middle;
  fill: currentColor;
  margin-right: 6px;
}

.comment-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  margin-right: 8px;
  vertical-align: middle;
}
.comment-author {
  font-weight: 600;
  color: #fff;
  margin-right: 4px;
}

.details-btn {
  background: #2196f3;
  color: #fff;
  border: none;
  border-radius: 7px;
  padding: 8px 22px;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
  box-shadow: 0 0 8px #2196f344;
  cursor: pointer;
  display: inline-block;
}
.details-btn:hover {
  background: #1565c0;
  color: #fff;
  box-shadow: 0 0 16px #2196f388;
}

.case-detail-views svg {
  width: 22px;
  height: 22px;
  display: inline-block;
  vertical-align: middle;
  margin-right: 4px;
  fill: #888;
}
.case-detail-views {
  display: flex;
  align-items: center;
  gap: 5px;
  color: #888;
  font-size: 1.05em;
}
.case-detail-back {
  position: absolute;
  top: 18px;
  left: 18px;
  right: auto;
  padding: 4px 14px;
  font-size: 0.98rem;
  min-width: unset;
  height: 32px;
  z-index: 2;
  background: #232323;
  color: #fff;
  border-radius: 7px;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: background 0.18s, color 0.18s;
  display: inline-block;
}
.case-detail-back:hover {
  background: #2196f3;
  color: #fff;
  text-decoration: none;
}
@media (max-width:700px) { .case-detail-back { top: 8px; left: 8px; right: auto; font-size: 0.93rem; padding: 3px 10px; } }
.case-detail-main { position: relative; max-width: 700px; margin: 40px auto; background: #181818; border-radius: 18px; padding: 38px 28px 32px 28px; box-shadow: 0 4px 32px #0008, 0 2px 16px #0004; border: 1.5px solid #333; animation: fadeInCase 1.1s cubic-bezier(.4,1.4,.6,1); }
.case-detail-title-row { display:flex; align-items:center; gap:14px; margin-bottom:10px; padding-top: 18px; }
.case-detail-title { font-size:1.5rem; font-weight:700; margin:0; flex:1; }
.case-detail-img { width:100%; border-radius:10px; margin-bottom:18px; object-fit:cover; background:#222; }
.case-detail-author { display:flex; align-items:center; gap:10px; margin-bottom:18px; }
.case-detail-author img { width:38px; height:38px; border-radius:50%; object-fit:cover; background:#fff; border:2px solid #2196f3; }
.case-detail-date { color:#888; font-size:0.98em; margin-left:8px; }
.case-detail-desc { color:#bdbdbd; font-size:1.08rem; margin-bottom:22px; white-space:pre-line; }
.case-detail-actions { display:flex; gap:14px; align-items:center; margin-bottom:18px; }
.case-detail-like-btn { background:#2196f3; color:#fff; border:none; border-radius:7px; padding:6px 12px; font-size:0.98rem; font-weight:600; cursor:pointer; transition:background 0.18s; display:flex; align-items:center; gap:6px; }
.case-detail-like-btn.liked { background:#e53935; }
.case-detail-like-btn:hover { background:#1565c0; }
.case-detail-like-btn svg { width: 1.1em; height: 1.1em; }
.case-detail-share-btn { background:#232323; color:#fff; border:none; border-radius:7px; padding:8px 18px; font-size:1rem; font-weight:600; cursor:pointer; transition:background 0.18s; }
.case-detail-share-btn:hover { background:#2196f3; color:#fff; }
.case-detail-comments-toggle { background:none; border:none; color:#2196f3; font-size:1.05em; cursor:pointer; margin-bottom:10px; }
.case-detail-comments { margin-top:10px; }
.case-detail-comment { display:flex; align-items:flex-start; gap:10px; margin-bottom:12px; }
.case-detail-comment .comment-avatar { width:32px; height:32px; }
.case-detail-comment .comment-body { background:#232323; border-radius:8px; padding:8px 14px; color:#bdbdbd; font-size:0.98rem; flex:1; }
.case-detail-comment .comment-author { font-weight:600; color:#fff; margin-right:4px; }
.case-detail-add-form { display:flex; gap:8px; margin-top:10px; }
.case-detail-add-form input[type="text"] { flex:1; background:#181818; color:#fff; border:1px solid #333; border-radius:6px; padding:7px 10px; font-size:0.98rem; }
.case-detail-add-form button { background:#2196f3; color:#fff; border:none; border-radius:6px; padding:7px 14px; font-size:0.98rem; font-weight:600; cursor:pointer; transition:background 0.18s; }
.case-detail-add-form button:hover { background:#1565c0; }
@media (max-width:700px) { .case-detail-main { padding:12px 2vw; } 
.case-detail-title { font-size:1.1rem; } }
.owner-label { color:#2196f3; font-size:0.98em; font-weight:600; margin-right:8px; background:#fff2; border-radius:5px; padding:2px 7px; }
.comment-date { margin-left: 12px; color: #888; font-size: 0.93em; display: inline-block; min-width: 70px; text-align: right; float: right; }
@media (max-width: 700px) { .comment-date { min-width: 56px; font-size: 0.91em; } }

.custom-file-btn {
  display: inline-block;
  background: #2196f3;
  color: #fff;
  border: none;
  border-radius: 7px;
  padding: 7px 18px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
  box-shadow: 0 0 8px #2196f344;
  margin-bottom: 6px;
  margin-right: 0;
  width: auto;
  min-width: 0;
  max-width: 220px;
  text-align: center;
}
.custom-file-btn:hover {
  background: #1565c0;
  color: #fff;
}
.file-name-label {
  color: #888;
  font-size: 0.98em;
  margin-left: 2px;
  margin-bottom: 8px;
  display: inline-block;
}
.custom-chk {
  width: 1.3em;
  height: 1.3em;
  accent-color: #2196f3;
  margin-right: 4px;
  vertical-align: middle;
}
.case-chk-all {
  width: 1.3em;
  height: 1.3em;
  accent-color: #2196f3;
  margin-right: 4px;
  vertical-align: middle;
}
.styled-btn {
  border: none;
  border-radius: 6px;
  padding: 7px 16px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
  margin: 0 2px;
  box-shadow: 0 0 8px #0002;
}
.styled-btn.edit {
  background: #2196f3;
  color: #fff;
}
.styled-btn.edit:hover {
  background: #1565c0;
  color: #fff;
}
.styled-btn.delete {
  background: #e53935;
  color: #fff;
}
.styled-btn.delete:hover {
  background: #b71c1c;
  color: #fff;
}
.admin-mass-del-btn {
  margin-top: 0 !important;
}

.admin-label {
  font-weight: 400;
  background: #2196f322;
  color: #2196f3;
  border-radius: 5px;
  padding: 2px 7px;
  margin-left: 6px;
  font-size: 0.97em;
}

/* --- About Section --- */
.about-mission {
  font-size: 1.18em;
  font-weight: 500;
  margin-bottom: 22px;
  color: #222;
  text-align: center;
}
.about-features {
  display: flex;
  flex-direction: column;
  gap: 24px;
  justify-content: center;
  align-items: stretch;
  margin-bottom: 28px;
}
.about-feature {
  background: #232428;
  color: #fff;
  border-radius: 14px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 18px 32px;
  min-width: 340px;
  max-width: 100%;
  width: 100%;
  margin-bottom: 0;
  transition: box-shadow 0.2s, background 0.2s;
  opacity: 0;
  transform: translateY(16px);
  will-change: transform, opacity;
}
.about-feature:hover {
  box-shadow: 0 4px 16px rgba(33,150,243,0.10);
  background: #282a2f;
}
.about-feature.af-in { opacity: 1; transform: none; transition: opacity .6s cubic-bezier(.4,1.4,.6,1), transform .6s cubic-bezier(.4,1.4,.6,1); }
.about-icon {
  font-size: 2.2em;
  margin-right: 6px;
  flex-shrink: 0;
  margin-top: 2px;
}
.about-icon svg {
  fill: #fff !important;
  color: #fff !important;
}
.about-feature b {
  color: #4fc3f7;
}
.about-feature p {
  margin: 4px 0 0 0;
  color: #e0e0e0;
  font-size: 0.98em;
}
.about-why {
  margin: 28px auto 18px auto;
  max-width: 600px;
  background: #232428;
  border-radius: 10px;
  padding: 18px 24px;
  font-size: 1.08em;
  color: #e0e0e0;
  box-shadow: 0 1px 6px rgba(33,150,243,0.07);
  border: none;
  transition: background 0.2s;
  position: relative;
}
.about-why:hover {
  background: #282a2f;
}
.about-why b {
  display: block;
  margin-bottom: 8px;
  color: #4fc3f7;
  font-size: 1.13em;
}
.about-why ul {
  margin: 0 0 0 18px;
  padding: 0;
}
.about-why:before {
  content: "";
  position: absolute;
  left: 12px;
  top: 52px;
  bottom: 18px;
  width: 2px;
  background: linear-gradient(180deg, rgba(79,195,247,0.35), rgba(33,150,243,0.25));
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 1s ease .2s;
}
.about-why.aw-in:before { transform: scaleY(1); }
.about-why li { position: relative; margin-bottom: 10px; list-style: none; color: #e0e0e0; padding-left: 24px; }
.about-why li:before { content: ""; position: absolute; left: 4px; top: 6px; width: 10px; height: 10px; border-radius: 50%; background: #4fc3f7; box-shadow: 0 0 0 3px rgba(79,195,247,0.18); }
.about-cta {
  text-align: center;
  margin-top: 18px;
  font-size: 1.13em;
  color: #1976d2;
}
.cta-link {
  color: #fff;
  background: #2196f3;
  border-radius: 6px;
  padding: 7px 18px;
  margin-left: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: background 0.18s;
  animation: ctaPulse 8s ease-in-out infinite;
}
.cta-link:hover {
  background: #1565c0;
}
@keyframes ctaPulse {
  0%, 90% { box-shadow: 0 0 0 0 rgba(33,150,243,0.0); }
  95% { box-shadow: 0 0 0 6px rgba(33,150,243,0.18); }
  100% { box-shadow: 0 0 0 0 rgba(33,150,243,0.0); }
}
@media (max-width: 900px) {
  .about-feature {
    min-width: 0;
    max-width: 100%;
    width: 100%;
    padding: 14px 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .about .about-bg { animation: none; }
  .about-feature, .about-mission { transition: none; opacity: 1 !important; transform: none !important; }
  .about-why:before { transition: none; transform: none; }
  .cta-link { animation: none; }
}

.services {
  margin-bottom: 60px;
  background: var(--secondary);
  border-radius: 18px;
  padding: 36px 28px;
  box-shadow: 0 2px 16px 0 rgba(0,0,0,0.08);
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}
.services h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 18px;
}
.services-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(260px, 1fr));
  gap: 22px;
}
.services-list li {
  position: relative;
  background: #1f1f24;
  color: #fff;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 24px 24px 26px 24px;
  transform-style: preserve-3d;
  transform: perspective(900px) rotateX(var(--rX,0)) rotateY(var(--rY,0)) translateZ(var(--tZ,0));
  transition: transform .35s cubic-bezier(.2,.8,.2,1), box-shadow .3s, background .25s;
  box-shadow: 0 12px 30px rgba(0,0,0,.25), inset 0 0 0 1px rgba(255,255,255,.04);
  isolation: isolate;
  overflow: hidden;
}
.services-list li:hover {
  box-shadow: 0 24px 60px rgba(33,150,243,0.18), 0 10px 22px rgba(0,0,0,.35);
  background: #26282e;
}
.services-list li::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(79,195,247,.25), rgba(33,150,243,.06));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: .8;
  pointer-events: none;
}
.services-list li::after {
  content: "";
  position: absolute;
  left: -40%; top: -150%;
  width: 80%; height: 300%;
  background: linear-gradient( 60deg, transparent 0%, rgba(255,255,255,.08) 50%, transparent 100%);
  transform: rotate(25deg);
  transition: transform .7s ease;
  pointer-events: none;
}
.services-list li:hover::after { transform: rotate(25deg) translateX(120%); }
.service-title {
  color: #4fc3f7;
  font-size: 1.13em;
  margin-bottom: 2px;
}
.service-desc {
  color: #e0e0e0;
  font-size: 1em;
}
@media (max-width: 900px) {
  .services { padding: 18px 4px; }
  .services-list { grid-template-columns: 1fr; }
  .services-list li { padding: 18px 16px; }
}

/* Services background canvas */
.services-canvas { position:absolute; inset:0; z-index:0; opacity:.22; filter: blur(0px) contrast(105%); }
.services > *:not(.services-canvas) { position: relative; z-index: 1; }

/* Reveal */
.services-list li { opacity: 0; transform: translateY(14px); }
.services-list li.sv-in { opacity: 1; transform: perspective(900px) rotateX(var(--rX,0)) rotateY(var(--rY,0)) translateZ(var(--tZ,0)); transition: opacity .5s ease, transform .5s cubic-bezier(.2,.8,.2,1); }

@media (prefers-reduced-motion: reduce) {
  .services-list li { transition: none; transform: none !important; opacity: 1 !important; }
  .services-canvas { display: none; }
}

.about-cta-box {
  background: none;
  border-radius: 0;
  box-shadow: none;
  padding: 0;
  max-width: 600px;
  margin: 24px auto 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  justify-content: center;
  text-align: center;
}
.about-cta {
  color: #fff;
  font-size: 1.13em;
  font-weight: 500;
  text-align: center;
}
@media (max-width: 700px) {
  .about-cta-box {
    flex-direction: column;
    text-align: center;
    gap: 10px;
    padding: 14px 8px;
  }
  .about-cta {
    font-size: 1em;
    text-align: center;
  }
}

/* --- Article Editor (Admin) --- */
.article-editor-form {
  background: #232323;
  border-radius: 16px;
  box-shadow: 0 4px 24px #0006, 0 2px 8px #0002;
  padding: 32px 24px 24px 24px;
  margin-bottom: 36px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}
.editor-section {
  margin-bottom: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.editor-title {
  font-size: 1.25rem;
  font-weight: 700;
  padding: 14px 12px;
  border-radius: 8px;
  border: 1.5px solid #333;
  background: #181818;
  color: #fff;
  margin-bottom: 0;
  box-shadow: 0 1px 4px #0002;
}
.editor-desc {
  min-height: 120px;
  font-size: 1.08rem;
  border-radius: 8px;
  border: 1.5px solid #333;
  background: #181818;
  color: #fff;
  padding: 12px;
  box-shadow: 0 1px 4px #0002;
}
.custom-file-btn {
  margin-top: 0;
  margin-bottom: 0;
  font-size: 1rem;
  padding: 7px 18px;
}
.file-name-label {
  color: #888;
  font-size: 0.98em;
  margin-left: 8px;
  margin-bottom: 8px;
  display: inline-block;
}
#image-preview img, #video-preview video {
  margin-top: 8px;
  border-radius: 8px;
  box-shadow: 0 2px 8px #0004;
}
.editor-btn {
  font-size: 1.08rem;
  font-weight: 700;
  border: none;
  border-radius: 8px;
  padding: 13px 32px;
  cursor: pointer;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
  box-shadow: 0 0 8px #2196f344;
}
.draft-btn {
  background: #232323;
  color: #fff;
  border: 1.5px solid #2196f3;
}
.draft-btn:hover {
  background: #1565c0;
  color: #fff;
}
.publish-btn {
  background: #2196f3;
  color: #fff;
}
.publish-btn:hover {
  background: #1565c0;
  color: #fff;
}
@media (max-width: 700px) {
  .article-editor-form {
    padding: 14px 4vw 14px 4vw;
    gap: 18px;
  }
  .editor-title {
    font-size: 1.08rem;
    padding: 10px 8px;
  }
  .editor-desc {
    font-size: 0.98rem;
    padding: 8px;
  }
  .editor-btn {
    font-size: 0.98rem;
    padding: 10px 18px;
  }
}
.instagram-btn {
  background: #2196f3 !important;
  color: #fff !important;
  border: 2px solid #2196f3;
  font-size: 1.2em;
  padding: 18px 38px;
  box-shadow: 0 2px 16px 0 rgba(33,150,243,0.25);
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}
.instagram-btn:hover, .instagram-btn:focus {
  background: #1565c0 !important;
  border-color: #1565c0;
  color: #fff !important;
  box-shadow: 0 4px 24px 0 rgba(33,150,243,0.35);
}
.instagram-link {
  color: #fff !important;
  text-decoration: underline;
  transition: color 0.2s;
}
.instagram-link:hover, .instagram-link:focus {
  color: #111 !important;
  background: #fff;
  border-radius: 3px;
  text-decoration: underline;
}