/* Shaxnoz Maktab — "Qora marmar va oltin" dizayni (shaxnoz-maktab.com) */
:root {
  --bg: #0d0f14; --bg2: #141821; --card: #1a1f2b; --line: rgba(212,175,55,.28);
  --gold: #d4af37; --gold-2: #f2db8a; --text: #eceff4; --muted: #9aa3b2;
  --serif: Georgia, 'Times New Roman', serif;
  --sans: system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --tr: all .3s cubic-bezier(.4,0,.2,1);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body { font-family: var(--sans); background: var(--bg); color: var(--text); line-height: 1.65; overflow-x: hidden; }
img { max-width: 100%; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 700; letter-spacing: .2px; }

/* Icons */
.i { width: 1.1em; height: 1.1em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; vertical-align: -.18em; flex-shrink: 0; }

/* Top bar + header */
.top-bar { background: #07080b; color: var(--muted); padding: 7px 6%; font-size: 12.5px; display: flex; justify-content: space-between; border-bottom: 1px solid var(--line); }
.top-bar-info span { margin-right: 22px; display: inline-flex; align-items: center; gap: 6px; }
.top-bar-info .i { color: var(--gold); }
header { position: sticky; top: 0; z-index: 1000; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 14px 6%; background: rgba(13,15,20,.92); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.logo { font-family: var(--serif); font-size: 25px; font-weight: 700; color: var(--gold); text-decoration: none; display: flex; align-items: center; gap: 10px; }
.nav-links { display: flex; list-style: none; gap: 30px; }
.nav-links a { color: var(--text); text-decoration: none; font-size: 14px; letter-spacing: .6px; text-transform: uppercase; padding-bottom: 4px; border-bottom: 1px solid transparent; transition: var(--tr); }
.nav-links a:hover { color: var(--gold); border-color: var(--gold); }
.header-right { display: flex; align-items: center; gap: 14px; }
.lang-switch { display: inline-flex; border: 1px solid var(--line); border-radius: 4px; overflow: hidden; font-size: 13px; font-weight: 600; }
.lang-switch a { padding: 7px 13px; color: var(--muted); text-decoration: none; transition: var(--tr); }
.lang-switch a:hover { color: var(--gold); }
.lang-switch a.is-active { background: var(--gold); color: #111; }
.btn-header { border: 1px solid var(--gold); color: var(--gold); padding: 9px 22px; border-radius: 4px; text-decoration: none; font-size: 13px; font-weight: 600; letter-spacing: .6px; text-transform: uppercase; transition: var(--tr); }
.btn-header:hover { background: var(--gold); color: #111; }

/* Buttons */
.btn-primary { display: inline-block; border: 0; cursor: pointer; text-decoration: none; background: linear-gradient(135deg, var(--gold-2), var(--gold) 55%, #b8921f); color: #14110a; font-weight: 700; font-size: 15px; letter-spacing: .5px; padding: 14px 34px; border-radius: 4px; box-shadow: 0 8px 24px rgba(212,175,55,.25); transition: var(--tr); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(212,175,55,.4); }
.btn-primary[disabled] { opacity: .7; cursor: wait; transform: none; }

/* Hero: matn chapda, rasm o'ngda */
.hero { height: 86vh; min-height: 560px; }
.slider { position: relative; width: 100%; height: 100%; overflow: hidden; background: var(--bg); }
.swiper-slide { position: absolute; inset: 0; display: flex; align-items: center; opacity: 0; visibility: hidden; transition: opacity .8s ease, visibility .8s; }
.swiper-slide.is-active { opacity: 1; visibility: visible; z-index: 1; }
.slide-bg { position: absolute; top: 0; right: 0; width: 62%; height: 100%; object-fit: cover; object-position: center 30%; clip-path: polygon(14% 0, 100% 0, 100% 100%, 0 100%); }
.slide-overlay { position: absolute; inset: 0; background: linear-gradient(90deg, var(--bg) 30%, rgba(13,15,20,.2) 75%); }
.slide-content { position: relative; z-index: 2; max-width: 560px; margin-left: 6%; text-align: left; }
.slide-badge { display: inline-block; color: var(--gold); font-size: 12.5px; letter-spacing: 2.5px; text-transform: uppercase; padding-bottom: 10px; margin-bottom: 18px; border-bottom: 1px solid var(--gold); }
.slide-title { font-size: 50px; line-height: 1.15; margin-bottom: 18px; }
.slide-content p { color: #c3cad6; font-size: 17px; margin-bottom: 30px; }
.slider-btn { position: absolute; bottom: 28px; z-index: 5; width: 46px; height: 46px; border: 1px solid var(--gold); background: rgba(13,15,20,.6); color: var(--gold); border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: var(--tr); }
.slider-btn:hover { background: var(--gold); color: #111; }
.slider-btn.prev { left: 6%; } .slider-btn.next { left: calc(6% + 58px); }
.slider-btn .i { width: 20px; height: 20px; }
.slider-dots { position: absolute; bottom: 42px; right: 6%; z-index: 5; display: flex; gap: 8px; }
.slider-dots button { width: 28px; height: 3px; border: 0; background: rgba(255,255,255,.4); cursor: pointer; padding: 0; transition: var(--tr); }
.slider-dots button.is-active { background: var(--gold); width: 44px; }

/* Sections */
.section { padding: 96px 6%; }
.section-alt { background: var(--bg2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-title { text-align: center; max-width: 720px; margin: 0 auto 60px; }
.section-title h2 { font-size: 38px; margin-bottom: 16px; }
.section-title h2::after { content: ''; display: block; width: 64px; height: 2px; background: var(--gold); margin: 16px auto 0; }
.section-title p { color: var(--muted); }

/* About */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 70px; align-items: center; max-width: 1200px; margin: 0 auto; }
.about-img { outline: 1px solid var(--gold); outline-offset: 14px; border-radius: 2px; }
.about-img picture, .about-img img { display: block; width: 100%; height: auto; aspect-ratio: 960 / 707; object-fit: cover; }
.about-content h2 { font-size: 32px; color: var(--gold); margin-bottom: 20px; }
.about-content p { color: #c3cad6; margin-bottom: 18px; }
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 30px; }
.stat-card { background: var(--card); border: 1px solid var(--line); padding: 20px 12px; text-align: center; }
.stat-card h4 { font-size: 30px; color: var(--gold); }
.stat-card p { font-size: 12px; color: var(--muted); margin: 0; text-transform: uppercase; letter-spacing: 1px; }

/* Kurslar: gorizontal kartalar */
.courses-grid { display: grid; grid-template-columns: 1fr; gap: 34px; max-width: 1100px; margin: 0 auto; }
.course-card { display: flex; background: var(--card); border: 1px solid var(--line); overflow: hidden; transition: var(--tr); }
.course-card:nth-child(even) { flex-direction: row-reverse; }
.course-card:hover { border-color: var(--gold); transform: translateY(-4px); }
.course-img-wrapper { position: relative; flex: 0 0 42%; min-height: 320px; overflow: hidden; }
.course-img-wrapper picture { display: block; width: 100%; height: 100%; }
.course-img { width: 100%; height: 100%; object-fit: cover; transition: var(--tr); }
.course-card:hover .course-img { transform: scale(1.05); }
.course-tag { position: absolute; top: 16px; left: 16px; z-index: 2; background: var(--gold); color: #111; padding: 4px 14px; font-size: 12px; font-weight: 700; letter-spacing: .6px; text-transform: uppercase; }
.course-body { position: relative; flex: 1; padding: 40px 38px; display: flex; flex-direction: column; justify-content: center; }
.course-num { position: absolute; top: 10px; right: 26px; font: 700 78px/1 var(--serif); color: rgba(212,175,55,.14); }
.course-body h3 { font-size: 28px; color: var(--gold-2); margin-bottom: 12px; }
.course-body p { color: #c3cad6; margin-bottom: 20px; }
.course-features { list-style: none; margin-bottom: 26px; }
.course-features li { display: flex; align-items: center; gap: 10px; color: var(--text); font-size: 14.5px; margin-bottom: 9px; }
.course-features .i { color: var(--gold); }
.course-body .btn-primary { align-self: flex-start; width: auto !important; }

/* Galereya: masonry */
.gallery-grid { columns: 3 260px; column-gap: 16px; max-width: 1200px; margin: 0 auto; }
.gallery-item { position: relative; margin: 0 0 16px; break-inside: avoid; overflow: hidden; border: 1px solid var(--line); background: var(--card); }
.gallery-item picture, .gallery-item img { display: block; width: 100%; height: auto; transition: var(--tr); }
.gallery-item:hover img { transform: scale(1.05); }
.gallery-item span { position: absolute; left: 0; bottom: 14px; background: var(--gold); color: #111; padding: 4px 14px 4px 12px; font-size: 12px; font-weight: 700; letter-spacing: .5px; text-transform: uppercase; }

/* Forma */
.registration-container { max-width: 720px; margin: 0 auto; padding: 46px; background: var(--card); border: 1px solid var(--line); box-shadow: 0 30px 60px rgba(0,0,0,.45); }
.form-group { margin-bottom: 22px; }
.form-group label { display: block; margin-bottom: 8px; font-size: 13px; font-weight: 600; letter-spacing: .5px; text-transform: uppercase; color: var(--gold-2); }
.form-control { width: 100%; padding: 14px 16px; background: #10131a; color: var(--text); border: 1px solid #2b3244; border-radius: 4px; font-size: 15px; outline: none; transition: var(--tr); }
.form-control::placeholder { color: #6b7488; }
.form-control:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(212,175,55,.15); }
select.form-control { appearance: none; background: #10131a url("data:image/svg+xml;utf8,<svg fill='%23d4af37' height='24' viewBox='0 0 24 24' width='24' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/></svg>") no-repeat right 12px center; }
.form-control option { background: #10131a; color: var(--text); }
.hp-field { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.form-status { margin-top: 14px; padding: 12px 16px; border-radius: 4px; font-size: 14px; display: none; }
.form-status.ok { display: block; background: rgba(16,185,129,.12); color: #6ee7b7; border: 1px solid rgba(16,185,129,.4); }
.form-status.err { display: block; background: rgba(239,68,68,.12); color: #fca5a5; border: 1px solid rgba(239,68,68,.4); }

/* Pop-up */
.popup-overlay { position: fixed; inset: 0; z-index: 2000; background: rgba(5,6,9,.82); backdrop-filter: blur(6px); display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transition: all .4s ease; padding: 16px; overflow-y: auto; }
.popup-overlay.active { opacity: 1; visibility: visible; }
.popup-box { position: relative; width: 100%; max-width: 480px; background: var(--card); border: 1px solid var(--gold); padding: 38px 30px; transform: scale(.85); transition: all .4s cubic-bezier(.34,1.56,.64,1); }
.popup-overlay.active .popup-box { transform: scale(1); }
.popup-close { position: absolute; top: 12px; right: 12px; width: 34px; height: 34px; border: 1px solid var(--line); background: transparent; color: var(--text); border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: var(--tr); }
.popup-close:hover { background: var(--gold); color: #111; }
.popup-close .i { width: 16px; height: 16px; }
.popup-box h3 { font-size: 26px; color: var(--gold); text-align: center; margin-bottom: 8px; }
.popup-box > p { text-align: center; color: var(--muted); font-size: 14px; margin-bottom: 24px; }

/* Suzuvchi tugmalar */
.floating-contacts { position: fixed; right: 26px; bottom: 28px; z-index: 999; display: flex; flex-direction: column; gap: 12px; }
.float-btn { width: 54px; height: 54px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; text-decoration: none; box-shadow: 0 6px 20px rgba(0,0,0,.45); transition: var(--tr); }
.float-btn:hover { transform: scale(1.12); }
.float-btn .i { width: 25px; height: 25px; }
.float-btn.telegram { background: #0088cc; }
.float-btn.instagram { background: linear-gradient(45deg, #f09433, #dc2743 55%, #bc1888); }
.float-btn.phone { background: #10b981; }
.float-btn.location { background: #ef4444; }
.float-btn.pulse { animation: pulse-ring 2s infinite; }
@keyframes pulse-ring { 0% { box-shadow: 0 0 0 0 rgba(16,185,129,.5); } 70% { box-shadow: 0 0 0 15px rgba(16,185,129,0); } 100% { box-shadow: 0 0 0 0 rgba(16,185,129,0); } }

/* Footer */
footer { background: #07080b; border-top: 1px solid var(--line); color: var(--muted); padding: 64px 6% 28px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.4fr; gap: 40px; margin-bottom: 40px; }
.footer-col h4 { color: var(--gold); font-size: 18px; margin-bottom: 18px; }
.footer-col p, .footer-col li { font-size: 14px; line-height: 2; }
.footer-col ul { list-style: none; }
.footer-col a { color: var(--muted); text-decoration: none; transition: var(--tr); }
.footer-col a:hover { color: var(--gold); }
.footer-col .i { color: var(--gold); }
.footer-bottom { text-align: center; border-top: 1px solid #1c2130; padding-top: 24px; font-size: 13px; }

/* Scroll animatsiya */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } .swiper-slide { transition: none; } html { scroll-behavior: auto; } }

/* Responsive */
@media (max-width: 992px) {
  .about-grid { grid-template-columns: 1fr; gap: 50px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .slide-title { font-size: 40px; }
}
@media (max-width: 768px) {
  .top-bar, .nav-links, .slider-btn { display: none; }
  .section { padding: 70px 5%; }
  .slide-bg { width: 100%; clip-path: none; }
  .slide-overlay { background: linear-gradient(180deg, rgba(13,15,20,.78), rgba(13,15,20,.9)); }
  .slide-content { margin: 0 6%; }
  .slide-title { font-size: 32px; }
  .slide-content p { font-size: 15px; }
  .slider-dots { right: auto; left: 6%; }
  .course-card, .course-card:nth-child(even) { flex-direction: column; }
  .course-img-wrapper { flex: none; height: 240px; min-height: 0; }
  .course-body { padding: 28px 22px; }
  .registration-container { padding: 30px 20px; }
  .footer-grid { grid-template-columns: 1fr; }
  .floating-contacts { right: 16px; bottom: 18px; }
  .float-btn { width: 46px; height: 46px; }
}
@media (max-width: 480px) { .btn-header { display: none; } }

/* Ishlab chiquvchi (spacey.uz) */
.footer-bottom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; text-align: left; }
.dev-credit { display: inline-flex; align-items: center; gap: 10px; color: var(--muted); text-decoration: none; font-size: 13px; transition: var(--tr); }
.dev-credit img { background: #fff; border-radius: 6px; padding: 3px 8px; width: auto; height: 30px; }
.dev-credit:hover { color: var(--gold); }
@media (max-width: 768px) { .footer-bottom { justify-content: center; text-align: center; } }
