@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Montserrat:wght@400;500;600;700&family=Unbounded:wght@400;500;600;700&display=swap');

/* ===== RESET & ROOT ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --accent: #E88D4D;
    --accent-hover: #D97A3A;
    --accent-rgb: 232, 141, 77;
    --border-light: #d2d2d6;
    --text-primary: #1d1d1f;
    --text-secondary: #6e6e73;
    --bg-body: #f5f5f7;
    --bg-white: #ffffff;
    --shadow-sm: 0 4px 20px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 8px 40px rgba(0, 0, 0, 0.08);
    --radius-md: 20px;
    --radius-lg: 28px;
    --radius-xl: 40px;
    --transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-body);
    font-family: 'Montserrat', sans-serif;
    color: var(--text-primary);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

/* ===== TYPOGRAPHY ===== */
h1 {
    font-size: clamp(2.4rem, 6vw, 4.6rem);
    font-weight: 600;
    letter-spacing: -0.025em;
    line-height: 1.1;
    color: var(--text-primary);
    font-family: 'Unbounded', cursive;
}

h2 {
    font-size: clamp(1.8rem, 3.5vw, 2.7rem);
    font-weight: 600;
    letter-spacing: -0.02em;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    font-family: 'Unbounded', cursive;
}

h3 {
    font-size: clamp(1.1rem, 1.8vw, 1.5rem);
    font-family: 'Unbounded', cursive;
    font-weight: 500;
}

p {
    font-size: 1rem;
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    color: var(--text-secondary);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px;
}

.section-badge {
    display: inline-block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--accent);
    font-weight: 600;
    margin-bottom: 8px;
    font-family: 'Montserrat', sans-serif;
}

/* ===== NAVBAR ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    backdrop-filter: blur(20px);
    background: rgba(245, 245, 247, 0.75);
    border-bottom: 0.5px solid var(--border-light);
    z-index: 100;
    padding: 12px 0;
    transition: var(--transition);
}

.navbar.scrolled {
    background: rgba(245, 245, 247, 0.92);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.04);
}

.nav-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: -0.03em;
    color: var(--text-primary);
    text-decoration: none;
    font-family: 'Unbounded', cursive;
}

/* ===== SNIP1226 NAV LINKS ===== */
.snip1226 {
    text-align: center;
    text-transform: uppercase;
    font-weight: 500;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.snip1226 * {
    box-sizing: border-box;
    transition: all 0.35s ease;
}

.snip1226 li {
    display: inline-block;
    list-style: outside none none;
    margin: 0 1.2em;
    overflow: hidden;
    line-height: 1;
}

.snip1226 a {
    padding: 0.3em 0;
    color: var(--text-primary);
    position: relative;
    display: inline-block;
    letter-spacing: 0.08em;
    margin: 0;
    text-decoration: none;
    cursor: pointer;
    font-weight: 500;
}

.snip1226 a:before,
.snip1226 a:after {
    position: absolute;
    transition: all 0.35s ease;
}

.snip1226 a:before {
    bottom: 100%;
    display: block;
    height: 2px;
    width: 100%;
    content: "";
    background-color: var(--accent);
}

.snip1226 a:after {
    padding: 0.3em 0;
    position: absolute;
    bottom: 100%;
    left: 0;
    content: attr(data-hover);
    color: var(--accent);
    white-space: nowrap;
}

.snip1226 li:hover a,
.snip1226 .current a {
    transform: translateY(100%);
}

/* ===== NAV CTA ===== */
.nav-cta {
    background: transparent;
    border: 1px solid var(--border-light);
    padding: 6px 18px;
    border-radius: 30px;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Montserrat', sans-serif;
}

.nav-cta:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(var(--accent-rgb), 0.05);
}

/* ===== HERO ===== */
.hero {
    min-height: 80vh;
    display: flex;
    align-items: center;
    padding-top: 80px;
    position: relative;
    overflow: hidden;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    width: 100%;
}

.hero-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-badge {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--accent);
    margin-bottom: 1rem;
    font-weight: 600;
    font-family: 'Montserrat', sans-serif;
}

.hero-desc {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin: 0.5rem 0 2rem;
    max-width: 480px;
}

.hero-btn {
    background: transparent;
    border: 1px solid var(--border-light);
    padding: 12px 28px;
    border-radius: 30px;
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Montserrat', sans-serif;
    align-self: flex-start;
}

.hero-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(var(--accent-rgb), 0.05);
}

.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    min-height: 300px;
}

.outline-shape {
    width: 280px;
    height: 280px;
    position: relative;
}

.aura {
    position: absolute;
    border-radius: 50%;
    filter: blur(50px);
    z-index: -1;
    pointer-events: none;
}

.aura-1 {
    width: 220px;
    height: 220px;
    top: -70px;
    right: -70px;
    background: rgba(var(--accent-rgb), 0.5);
    animation: auraPulse1 4s ease-in-out infinite;
}

.aura-2 {
    width: 200px;
    height: 200px;
    bottom: -60px;
    left: -60px;
    background: rgba(var(--accent-rgb), 0.4);
    animation: auraPulse2 3.5s ease-in-out infinite 0.5s;
}

.aura-3 {
    width: 160px;
    height: 160px;
    top: 50%;
    right: -80px;
    transform: translateY(-50%);
    background: rgba(255, 153, 0, 0.3);
    animation: auraPulse3 5s ease-in-out infinite 1s;
}

@keyframes auraPulse1 {
    0%, 100% { opacity: 0.4; transform: translate(0,0) scale(1); }
    50% { opacity: 0.7; transform: translate(15px,-12px) scale(1.1); }
}

@keyframes auraPulse2 {
    0%, 100% { opacity: 0.4; transform: translate(0,0) scale(1); }
    50% { opacity: 0.6; transform: translate(-20px,15px) scale(1.08); }
}

@keyframes auraPulse3 {
    0%, 100% { opacity: 0.3; transform: translateY(-50%) scale(1); }
    50% { opacity: 0.5; transform: translateY(-50%) scale(1.05); }
}

/* ===== ABOUT ===== */
.about {
    padding: 80px 0;
    border-top: 0.5px solid var(--border-light);
    background: var(--bg-white);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

.about-left {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.about-left p {
    font-size: 1.05rem;
    line-height: 1.65;
    max-width: 560px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: 4px;
}

.stats-card {
    text-align: center;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 20px 12px;
    transition: var(--transition);
}

.stats-card:hover {
    border-color: var(--accent);
    background: rgba(var(--accent-rgb), 0.02);
    transform: translateY(-3px);
}

.stats-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 4px;
    font-family: 'Unbounded', cursive;
}

.stats-title {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.about-image {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.main-team-photo {
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-sm);
    width: 100%;
    aspect-ratio: 4/3;
    background: #f0f0f2;
}

.team-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.main-team-photo:hover .team-photo {
    transform: scale(1.03);
}

.team-thumbnails {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.thumbnail {
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border-light);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    aspect-ratio: 4/3;
    background: #f0f0f2;
}

.thumbnail.active {
    border-color: var(--accent);
    box-shadow: 0 0 0 2px var(--accent);
}

.thumbnail:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(var(--accent-rgb), 0.12);
}

.thumbnail-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.thumbnail:hover .thumbnail-img {
    transform: scale(1.05);
}

.thumbnail-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.thumbnail:hover .thumbnail-overlay {
    opacity: 1;
}

.thumbnail-label {
    color: white;
    font-size: 0.75rem;
    font-weight: 500;
    font-family: 'Montserrat', sans-serif;
    text-align: center;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    backdrop-filter: blur(4px);
}

/* ===== VALUES / ICEBERG ===== */
.values {
    padding: 80px 0;
    background: var(--bg-body);
    border-top: 0.5px solid var(--border-light);
}

.values-header {
    text-align: center;
    margin-bottom: 40px;
}

.values-header .section-badge {
    margin-bottom: 4px;
}

.values-desc {
    max-width: 560px;
    margin: 0 auto;
    color: var(--text-secondary);
    font-size: 1.05rem;
}

.iceberg-layout {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 50px;
    align-items: start;
}

.iceberg-text {
    display: flex;
    flex-direction: column;
    gap: 24px;
    padding-top: 10px;
}

.iceberg-dynamic {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.dynamic-item {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    padding: 18px 22px;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    transition: var(--transition);
    cursor: default;
}

.dynamic-item.active {
    background: rgba(255, 255, 255, 0.85);
    border-color: var(--border-light);
    box-shadow: var(--shadow-sm);
    transform: translateX(6px);
}

.dynamic-item.highlight-innovation {
    border-left: 4px solid #E88D4D;
    background: rgba(232, 141, 77, 0.06);
}
.dynamic-item.highlight-reliability {
    border-left: 4px solid #3a8ec4;
    background: rgba(58, 142, 196, 0.06);
}
.dynamic-item.highlight-passion {
    border-left: 4px solid #1a3a5c;
    background: rgba(26, 58, 92, 0.06);
}

.dynamic-icon {
    font-size: 1.6rem;
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 12px;
    border: 1px solid var(--border-light);
}

.dynamic-content h3 {
    font-size: 1.1rem;
    margin-bottom: 2px;
}

.dynamic-content p {
    font-size: 0.85rem;
    line-height: 1.5;
    margin-bottom: 4px;
}

.dynamic-tag {
    display: inline-block;
    font-size: 0.55rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 2px 12px;
    border-radius: 20px;
    background: rgba(0, 0, 0, 0.04);
    color: var(--text-secondary);
    font-weight: 600;
}

.iceberg-legend {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.legend-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    border: 1px solid var(--border-light);
    padding: 6px 16px;
    border-radius: 30px;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Montserrat', sans-serif;
}

.legend-btn:hover {
    border-color: var(--accent);
    color: var(--text-primary);
}

.legend-btn.active {
    border-color: var(--accent);
    background: rgba(var(--accent-rgb), 0.06);
    color: var(--accent);
}

.legend-btn .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
}

.legend-btn .top-dot { background: #E88D4D; }
.legend-btn .mid-dot { background: #3a8ec4; }
.legend-btn .bot-dot { background: #1a3a5c; }

.iceberg-visual {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.iceberg-svg {
    width: 100%;
    max-width: 720px;
    height: auto;
    background: transparent;
    filter: drop-shadow(0 8px 40px rgba(0, 0, 0, 0.03));
}

.ice-section {
    cursor: pointer;
}

.ice-section polygon,
.ice-section circle,
.ice-section text {
    transition: var(--transition);
}

.ice-section:hover polygon,
.ice-section.active-level polygon {
    stroke-width: 2;
}

.top-ice:hover polygon,
.top-ice.active-level polygon {
    fill: rgba(232, 141, 77, 0.12);
    stroke: #E88D4D;
    filter: url(#glow);
}

.middle-ice:hover polygon,
.middle-ice.active-level polygon {
    fill: rgba(58, 142, 196, 0.15);
    stroke: #3a8ec4;
    filter: url(#glow);
}

.bottom-ice:hover polygon,
.bottom-ice.active-level polygon {
    fill: rgba(26, 58, 92, 0.10);
    stroke: #1a3a5c;
    filter: url(#glow);
}

.info-branch {
    cursor: pointer;
}

.branch-line,
.branch-dot {
    transition: var(--transition);
}

.bubble {
    animation: floatBubble 4s ease-in-out infinite;
    transform-origin: center;
    transform-box: fill-box;
}
.bubble:nth-child(2) { animation-delay: 1s; animation-duration: 5s; }
.bubble:nth-child(3) { animation-delay: 2s; animation-duration: 3.5s; }
.bubble:nth-child(4) { animation-delay: 0.5s; animation-duration: 4.5s; }

@keyframes floatBubble {
    0%, 100% { transform: translateY(0) scale(1); opacity: 0.15; }
    50% { transform: translateY(-12px) scale(1.4); opacity: 0.4; }
}

/* ===== PROJECTS ===== */
.projects {
    padding: 80px 0;
    background: var(--bg-white);
    border-top: 0.5px solid var(--border-light);
}

.projects .section-badge {
    margin-bottom: 2px;
}

.projects-desc {
    color: var(--text-secondary);
    margin-bottom: 32px;
    font-size: 1.05rem;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.value-card {
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 32px;
    transition: var(--transition);
    display: flex;
    gap: 18px;
    align-items: flex-start;
}

.value-card:hover {
    border-color: var(--accent);
    background: rgba(var(--accent-rgb), 0.02);
    transform: translateY(-4px);
    box-shadow: var(--shadow-sm);
}

.value-icon {
    font-size: 1.8rem;
    opacity: 0.7;
    flex-shrink: 0;
}

.value-content h3 {
    font-size: 1.2rem;
    margin-bottom: 4px;
}

.value-content p {
    font-size: 0.85rem;
    line-height: 1.5;
}

/* ===== TEAM ===== */
.team-members {
    padding: 80px 0;
    background: var(--bg-body);
    border-top: 0.5px solid var(--border-light);
}

.team-members .section-badge {
    display: block;
    text-align: center;
}

.team-members h2 {
    text-align: center;
}

.team-desc {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 32px;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 32px;
    max-width: 900px;
    margin: 0 auto;
    justify-items: center;
}

.member {
    text-align: center;
    width: 100%;
    max-width: 220px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.silhouette {
    width: 150px;
    height: 150px;
    background: #e8e8ed;
    border-radius: 50%;
    margin: 0 auto 14px;
    overflow: hidden;
    transition: var(--transition);
    cursor: pointer;
    flex-shrink: 0;
}

.member-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.member:hover .silhouette {
    background: var(--accent);
    transform: scale(1.02);
}

.member h4 {
    font-size: 1rem;
    font-weight: 500;
    font-family: 'Unbounded', cursive;
    margin-top: 4px;
}

.member p {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 2px;
    flex: 1;
}

.member-btn {
    background: transparent;
    border: 1px solid var(--border-light);
    padding: 4px 16px;
    border-radius: 30px;
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
    margin-top: 10px;
    font-family: 'Montserrat', sans-serif;
}

.member-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(var(--accent-rgb), 0.05);
}

/* ===== АДАПТИВ ДЛЯ РАЗНОГО КОЛИЧЕСТВА УЧАСТНИКОВ ===== */
.team-grid:has(.member:only-child) {
    grid-template-columns: 1fr;
    justify-items: center;
}

.team-grid:has(.member:nth-child(2):last-child) {
    grid-template-columns: repeat(2, 1fr);
    max-width: 500px;
    justify-items: center;
}

.team-grid:has(.member:nth-child(3):last-child) {
    grid-template-columns: repeat(3, 1fr);
    max-width: 700px;
    justify-items: center;
}

.team-grid:has(.member:nth-child(4):last-child) {
    grid-template-columns: repeat(4, 1fr);
    max-width: 900px;
    justify-items: center;
}

.team-grid:has(.member:nth-child(5):last-child),
.team-grid:has(.member:nth-child(6):last-child) {
    grid-template-columns: repeat(3, 1fr);
    max-width: 800px;
    justify-items: center;
}

/* ===== JOIN ===== */
.join-section {
    padding: 80px 0;
    background: var(--bg-white);
    border-top: 0.5px solid var(--border-light);
}

.join-card {
    display: flex;
    gap: 48px;
    align-items: center;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    padding: 48px;
    background: var(--bg-body);
}

.join-content {
    flex: 1;
}

.join-content .section-badge {
    margin-bottom: 2px;
}

.join-content p {
    margin: 12px 0;
    max-width: 460px;
}

.join-features {
    display: flex;
    gap: 24px;
    margin: 16px 0 24px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    font-family: 'Montserrat', sans-serif;
}

.feature-item i {
    color: var(--accent);
}

.join-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.btn {
    padding: 10px 24px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Montserrat', sans-serif;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
}

.btn-primary {
    background: var(--accent);
    color: white;
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(var(--accent-rgb), 0.25);
}

.btn-secondary {
    background: transparent;
    border: 1px solid var(--border-light);
    color: var(--text-primary);
}

.btn-secondary:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(var(--accent-rgb), 0.05);
}

.join-image {
    flex: 1;
    text-align: center;
}

.join-img {
    max-width: 300px;
    opacity: 0.9;
}

.cta-section {
    padding: 60px 0 40px;
    background: var(--bg-body);
    border-top: none;
}

.cta-dark-card {
    position: relative;
    background: #0a0a0a;
    color: #ffffff;
    border-radius: 40px 40px 56px 56px;
    padding: 4rem 3rem 3.5rem;
    text-align: center;
    overflow: hidden;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.25);
    max-width: 2000px;
    margin: 0 auto;
}

.cta-dark-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(
        ellipse at center,
        rgba(255, 255, 255, 0.06) 0%,
        rgba(255, 255, 255, 0.02) 30%,
        transparent 70%
    );
    pointer-events: none;
}

.cta-dark-card::after {
    content: "";
    position: absolute;
    bottom: -50%;
    left: 50%;
    transform: translateX(-50%);
    width: 70%;
    height: 100%;
    background: radial-gradient(
        ellipse,
        rgba(232, 141, 77, 0.18) 0%,
        transparent 60%
    );
    pointer-events: none;
}

.cta-dark-card__title {
    position: relative;
    z-index: 1;
    font-family: 'Inter', 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: clamp(1.5rem, 3.6vw, 2.5rem);
    font-weight: 600;
    letter-spacing: -0.03em;
    line-height: 1.25;
    color: #ffffff;
    margin: 0 0 1.2rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: baseline;
    gap: 0.35em 0.45em;
    max-width: 780px;
    margin-left: auto;
    margin-right: auto;
    contain: layout style;
}

.cta-dark-card__btn {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    background: #ffffff;
    color: #0a0a0a;
    border: none;
    padding: 1rem 2.4rem;
    border-radius: 40px;
    font-family: 'Inter', 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    line-height: 1;
    cursor: pointer;
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1),
                box-shadow 0.3s cubic-bezier(0.25, 1, 0.5, 1),
                background 0.3s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06),
                0 8px 24px rgba(255, 255, 255, 0.08);
}

/* Лёгкий блеск при наведении */
.cta-dark-card__btn::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(
        120deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.4) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.cta-dark-card__btn:hover {
    transform: translateY(-3px);
    background: #ffffff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08),
                0 16px 40px rgba(255, 255, 255, 0.25);
}

.cta-dark-card__btn:hover::before {
    opacity: 1;
}

.cta-dark-card__btn:active {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08),
                0 6px 16px rgba(255, 255, 255, 0.18);
}

.cta-dark-card__btn:focus-visible {
    outline: 2px solid rgba(232, 141, 77, 0.7);
    outline-offset: 4px;
}

.cta-dark-card__title > span {
    display: inline-block;
}

/* Слово, которое меняется */
.word-swap {
    color: var(--accent);
    position: relative;
    /* view-transition-name зададим через JS, чтобы работало динамически */
}

.word-swap.is-animating-out {
    animation: wordSlideOut 0.4s cubic-bezier(0.310, 1.280, 0.320, 1.275) forwards;
}

.word-swap.is-animating-in {
    animation: wordSlideIn 0.4s cubic-bezier(0.310, 1.280, 0.320, 1.275) forwards;
}

@keyframes wordSlideOut {
    100% {
        opacity: 0;
        transform: translateY(100%);
    }
}

@keyframes wordSlideIn {
    0% {
        opacity: 0;
        transform: translateY(-100%);
    }
}

/* ============================================================
   VIEW TRANSITIONS API (Chrome / Edge / Opera)
   ============================================================ */
::view-transition-old(word-swap),
::view-transition-new(word-swap) {
    height: 100%;
    object-fit: none;
    object-position: top left;
    animation-timing-function: cubic-bezier(0.310, 1.280, 0.320, 1.275);
    animation-duration: 0.4s;
}

::view-transition-old(word-swap) {
    animation-name: vtSlideOut;
}

::view-transition-new(word-swap) {
    animation-name: vtSlideIn;
}

@keyframes vtSlideOut {
    100% {
        opacity: 0;
        translate: 0 100%;
    }
}

@keyframes vtSlideIn {
    0% {
        opacity: 0;
        translate: 0 -100%;
    }
}

/* ===== FOOTER CARD — прижат к CTA ===== */
.footer-card-wrapper {
    position: relative;
    padding: 20px 1.5rem 2rem;
    background: var(--bg-body);
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.footer-card {
    width: 100%;
    max-width: 1200px;
    background: #ffffff;
    border-radius: 28px;
    padding: 3rem 3rem 0;
    box-shadow: 0 4px 40px rgba(0, 0, 0, 0.04),
                0 1px 3px rgba(0, 0, 0, 0.02);
    font-family: 'Inter', 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif;
}

.footer-card__main {
    display: grid;
    grid-template-columns: 1.2fr 2fr;
    gap: 4rem;
    padding-bottom: 3rem;
}

.footer-card__brand {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-card__logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: 'Inter', 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 1.25rem;
    color: #0a0a0a;
    letter-spacing: -0.02em;
    margin-bottom: 0.3rem;
}

.footer-card__logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    color: #0a0a0a;
    font-size: 1.4rem;
}

.footer-card__logo-text {
    font-weight: 700;
}

.footer-card__desc {
    font-size: 0.85rem;
    line-height: 1.65;
    color: #86868b;
    margin: 0;
    max-width: 320px;
}

.footer-card__social {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.footer-card__social a {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #86868b;
    background: #f5f5f7;
    transition: all 0.25s ease;
    text-decoration: none;
    font-size: 0.95rem;
}

.footer-card__social a:hover {
    background: #0a0a0a;
    color: #ffffff;
    transform: translateY(-2px);
}

.footer-card__nav {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.footer-card__col {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-card__col-title {
    font-family: 'Inter', 'Montserrat', sans-serif;
    font-size: 0.8rem;
    font-weight: 700;
    color: #0a0a0a;
    margin: 0 0 0.5rem;
    letter-spacing: -0.01em;
}

.footer-card__link {
    font-size: 0.85rem;
    color: #86868b;
    text-decoration: none;
    transition: color 0.2s ease;
    line-height: 1.4;
}

.footer-card__link:hover {
    color: #0a0a0a;
}

.footer-card__bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 0;
    border-top: 1px solid #f0f0f2;
    font-size: 0.8rem;
    color: #86868b;
}

.footer-card__copyright {
    font-family: 'Inter', 'Montserrat', sans-serif;
}

.footer-card__legal {
    display: flex;
    gap: 1.5rem;
}

.footer-card__legal a {
    color: #86868b;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-card__legal a:hover {
    color: #0a0a0a;
}

/* ===== MODALS ===== */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    z-index: 99999; /* 🔝 гарантированно выше всего на странице */
    align-items: center;
    justify-content: center;
    padding: 20px;
    overflow-y: auto; 
    isolation: isolate;
}

.modal.show,
.modal[style*="display: flex"] {
    display: flex !important;
}

.modal-content {
    background: var(--bg-body);
    border-radius: var(--radius-xl);
    max-width: 520px;
    width: 100%;
    position: relative;
    padding: 32px;
    border: 1px solid var(--border-light);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.35);
    animation: modalSlide 0.3s ease;
    z-index: 1;
    isolation: isolate;
}

@keyframes modalSlide {
    from { opacity: 0; transform: translateY(20px) scale(0.97); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.close-modal {
    position: absolute;
    top: 16px;
    right: 20px;
    font-size: 28px;
    cursor: pointer;
    color: var(--text-secondary);
    transition: color 0.2s;
    line-height: 1;
}

.close-modal:hover {
    color: var(--accent);
}

.modal-header {
    margin-bottom: 24px;
}

.modal-header h3 {
    font-size: 1.6rem;
    font-weight: 600;
}

.modal-subtitle {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.contact-method {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    border: 1px solid var(--border-light);
    border-radius: 40px;
    text-decoration: none;
    color: var(--text-primary);
    transition: var(--transition);
    font-weight: 500;
    font-size: 0.9rem;
}

.contact-method:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(var(--accent-rgb), 0.05);
}

.contact-method i {
    width: 24px;
    font-size: 1.2rem;
}

.team-modal .modal-content {
    max-width: 600px;
}

.modal-member-layout {
    display: flex;
    gap: 24px;
    align-items: flex-start;
}

.member-modal-photo {
    flex-shrink: 0;
    width: 120px;
    border-radius: var(--radius-md);
    overflow: hidden;
    background: #e8e8ed;
    border: 1px solid var(--border-light);
}

.member-modal-photo img {
    width: 100%;
    height: auto;
    display: block;
}

.member-modal-info h3 {
    font-size: 1.4rem;
    font-weight: 600;
}

.member-modal-role {
    display: inline-block;
    background: rgba(var(--accent-rgb), 0.12);
    padding: 2px 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--accent);
    margin: 4px 0 12px;
}

.member-modal-bio {
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 16px;
}

.member-page-btn {
    display: inline-block;
    border: 1px solid var(--border-light);
    padding: 6px 20px;
    border-radius: 30px;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-primary);
    text-decoration: none;
    transition: var(--transition);
}

.member-page-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(var(--accent-rgb), 0.05);
}

/* Gallery Modal */
.gallery-modal .modal-content {
    max-width: 700px;
}

.gallery-container {
    display: flex;
    align-items: center;
    gap: 12px;
}

.gallery-nav {
    background: transparent;
    border: 1px solid var(--border-light);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    font-size: 16px;
    flex-shrink: 0;
}

.gallery-nav:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.gallery-slide {
    text-align: center;
    flex: 1;
}

.gallery-image {
    max-width: 100%;
    max-height: 50vh;
    border-radius: var(--radius-md);
}

.gallery-counter {
    margin-top: 8px;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.gallery-thumbnails {
    display: flex;
    gap: 10px;
    margin-top: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.gallery-thumb {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: var(--transition);
}

.gallery-thumb.active {
    border-color: var(--accent);
}

.gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ===== NAV RIGHT WRAPPER ===== */
.nav-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* ===== LANG TOGGLE ===== */
.lang-toggle {
    background: transparent;
    border: 1px solid var(--border-light);
    padding: 5px 12px;
    border-radius: 30px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 4px;
}

.lang-toggle:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(var(--accent-rgb), 0.05);
}

.lang-toggle__current {
    color: var(--text-primary);
    font-weight: 700;
}

.lang-toggle__divider {
    opacity: 0.4;
}

.lang-toggle__other {
    opacity: 0.55;
}

.lang-toggle:hover .lang-toggle__current,
.lang-toggle:hover .lang-toggle__other {
    color: var(--accent);
}

body.modal-open {
    overflow: hidden !important;
}

body.modal-open .navbar {
    z-index: 1 !important;
}

body.modal-open .sticky-card,
body.modal-open .sticky-card-wrapper,
body.modal-open .cta-banner-wrapper {
    z-index: 1 !important;
    pointer-events: none;
}

/* На всякий случай — глобальные правила */
body > .modal {
    z-index: 99999;
}

body > .modal.show {
    display: flex;
}

/* Модалка поверх любых элементов с backdrop-filter / transform */
.modal .modal-content {
    transform: translateZ(0);
    will-change: transform;
}

/* Убеждаемся, что SVG-фильтры и анимации не выходят за пределы */
.modal,
.modal * {
    pointer-events: auto;
}

/* Прокрутка длинных модалок */
.modal > .modal-content {
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--border-light) transparent;
}

.modal > .modal-content::-webkit-scrollbar {
    width: 6px;
}

.modal > .modal-content::-webkit-scrollbar-track {
    background: transparent;
}

.modal > .modal-content::-webkit-scrollbar-thumb {
    background: var(--border-light);
    border-radius: 6px;
}

/* ===== PROJECTS ===== */
.projects {
    padding: 80px 0;
    background: var(--bg-white);
    border-top: 0.5px solid var(--border-light);
}

.projects-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 32px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.projects-header h2 { margin-bottom: 4px; }

.projects-desc {
    color: var(--text-secondary);
    font-size: 1.05rem;
    margin: 0;
    max-width: 520px;
}

/* ===== Фильтры ===== */
.projects-filters {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.filter-btn {
    background: transparent;
    border: 1px solid var(--border-light);
    padding: 8px 18px;
    border-radius: 30px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
}

.filter-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.filter-btn.is-active {
    background: #0a0a0a;
    color: #ffffff;
    border-color: #0a0a0a;
}

/* ============================================================
   СПИСОК ПРОЕКТОВ — минималистичный, с крупным номером
   ============================================================ */
.projects-list {
    display: flex;
    flex-direction: column;
    border-top: 1px solid var(--border-light);
}

.proj {
    position: relative;
    display: grid;
    grid-template-columns: 80px 1fr auto;
    gap: 32px;
    align-items: center;
    padding: 32px 8px 32px 0;
    border-bottom: 1px solid var(--border-light);
    text-decoration: none;
    color: inherit;
    transition: background 0.4s cubic-bezier(0.25, 1, 0.5, 1),
                padding 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    cursor: pointer;
    overflow: hidden;
}

/* Полоса-акцент слева при ховере */
.proj::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--accent);
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

.proj:hover {
    background: linear-gradient(
        90deg,
        rgba(var(--accent-rgb), 0.05) 0%,
        transparent 60%
    );
    padding-left: 24px;
}

.proj:hover::before {
    transform: scaleY(1);
}

/* Номер проекта */
.proj__index {
    font-family: 'Unbounded', cursive;
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--border-light);
    letter-spacing: -0.02em;
    transition: color 0.3s ease, transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    align-self: flex-start;
    padding-top: 4px;
    line-height: 1;
}

.proj:hover .proj__index {
    color: var(--accent);
    transform: translateX(4px);
}

/* Основной блок */
.proj__main {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 0;
}

.proj__head {
    display: flex;
    align-items: baseline;
    gap: 16px;
    flex-wrap: wrap;
}

.proj__title {
    font-family: 'Unbounded', cursive;
    font-size: clamp(1.1rem, 2vw, 1.5rem);
    font-weight: 600;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    margin: 0;
    line-height: 1.2;
    transition: color 0.25s ease;
}

.proj:hover .proj__title {
    color: var(--accent);
}

.proj__year {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-secondary);
    letter-spacing: 0.08em;
    padding: 2px 10px;
    border: 1px solid var(--border-light);
    border-radius: 20px;
}

.proj__desc {
    font-size: 0.92rem;
    line-height: 1.6;
    color: var(--text-secondary);
    margin: 0;
    max-width: 640px;
}

/* Теги */
.proj__tags {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 2px;
}

.proj__tag {
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-secondary);
    font-family: 'Montserrat', sans-serif;
    padding: 3px 10px;
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.03);
    transition: background 0.25s ease, color 0.25s ease;
}

.proj:hover .proj__tag {
    background: rgba(var(--accent-rgb), 0.08);
    color: var(--accent);
}

/* Правая колонка — статус и стрелка */
.proj__meta {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-shrink: 0;
}

/* Статус */
.proj__status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-family: 'Montserrat', sans-serif;
    white-space: nowrap;
}

.proj__status::before {
    content: "";
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
}

.proj__status--live {
    color: #16a34a;
}

.proj__status--live::before {
    background: #16a34a;
    box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.6);
    animation: pulseLive 1.8s ease-in-out infinite;
}

.proj__status--wip {
    color: var(--accent);
}

.proj__status--wip::before {
    background: var(--accent);
    animation: pulseWip 2.4s ease-in-out infinite;
}

@keyframes pulseLive {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.55);
        opacity: 1;
    }
    50% {
        box-shadow: 0 0 0 6px rgba(22, 163, 74, 0);
        opacity: 0.85;
    }
}

@keyframes pulseWip {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* Стрелка */
.proj__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid var(--border-light);
    background: transparent;
    color: var(--text-primary);
    text-decoration: none;
    font-size: 1.05rem;
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1),
                background 0.3s ease,
                border-color 0.3s ease,
                color 0.3s ease;
    flex-shrink: 0;
}

.proj:hover .proj__link {
    background: var(--accent);
    border-color: var(--accent);
    color: #ffffff;
    transform: rotate(0deg) scale(1.05);
}

.proj__link i {
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

.proj:hover .proj__link i {
    transform: translate(1px, -1px);
}

/* Скрытие карточек при фильтрации */
.proj.is-hidden {
    display: none;
}

.proj.is-appearing {
    animation: projFadeIn 0.5s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

@keyframes projFadeIn {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== CTA под проектами ===== */
.projects-cta {
    margin-top: 48px;
    padding: 32px;
    background: var(--bg-body);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    flex-wrap: wrap;
}

.projects-cta p {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 0;
    max-width: 520px;
}