/* Global Styles */
* {
    box-sizing: border-box;
}

:root {
    --primary-color: #D4AF37;
    /* Gold */
    --secondary-color: #002366;
    /* Royal Blue */
    --dark-bg: #001233;
    --glass-bg: rgba(0, 35, 102, 0.7);
    --glass-border: rgba(212, 175, 55, 0.3);
    --text-color: #ffffff;
    --gold-gradient: linear-gradient(135deg, #D4AF37 0%, #F1D38E 50%, #D4AF37 100%);
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Outfit', sans-serif;
    color: var(--text-color);
    background-color: var(--dark-bg);
    overflow-x: hidden;
    scroll-behavior: smooth;
    opacity: 1 !important;
    /* Ensure body is never invisible */
}

/* Fixed Background Canvas */
#blockchain-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: radial-gradient(circle at center, #001a4d 0%, #00081a 100%);
    pointer-events: none;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #00152a;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

/* Navigation */
.nav-dots {
    position: fixed;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 100;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.nav-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(212, 175, 55, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.nav-dot.active {
    background: var(--primary-color);
    box-shadow: 0 0 15px var(--primary-color);
    transform: scale(1.4);
}

.nav-dot:hover {
    background: rgba(255, 255, 255, 0.8);
}

/* Header / Hero Section */
.hero-section {
    position: relative;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    overflow: hidden;
    z-index: 10;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../img/nen.jpg');
    background-size: cover;
    background-position: center;
    filter: blur(4px) brightness(0.5);
    z-index: -1;
    transform: scale(1.1);
    /* Prevent blur edges */
}

.hero-content {
    z-index: 2;
    animation: fadeInUp 1.2s ease-out;
}

.logo {
    max-width: 250px;
    height: auto;
    margin-bottom: 1.5rem;
    filter: drop-shadow(0 0 20px rgba(0, 170, 255, 0.6));
}

.company-name {
    font-family: 'Playfair Display', serif;
    font-size: 4rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 4px;
    margin: 0;
    background: var(--gold-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
}

.hero-slogan {
    font-size: 1.8rem;
    color: #fff;
    margin-top: 15px;
    font-weight: 500;
    letter-spacing: 1px;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: #f0f0f0;
    margin-top: 10px;
    opacity: 0.8;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Shooting Stars Effect */
.shooting-stars {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.star {
    position: absolute;
    top: 50%;
    left: 50%;
    height: 2px;
    background: linear-gradient(-45deg, #5f91ff, rgba(0, 0, 255, 0));
    filter: drop-shadow(0 0 6px #699bff);
    animation: tail 3000ms ease-in-out infinite, shooting 3000ms ease-in-out infinite;
}

.star::before,
.star::after {
    content: '';
    position: absolute;
    top: calc(50% - 1px);
    right: 0;
    height: 2px;
    background: linear-gradient(-45deg, rgba(0, 0, 255, 0), #5f91ff, rgba(0, 0, 255, 0));
    border-radius: 100%;
    transform: translateX(50%) rotateZ(45deg);
    animation: shining 3000ms ease-in-out infinite;
}

.star::after {
    transform: translateX(50%) rotateZ(-45deg);
}

@keyframes tail {
    0% {
        width: 0;
    }

    30% {
        width: 100px;
    }

    100% {
        width: 0;
    }
}

@keyframes shining {
    0% {
        width: 0;
    }

    50% {
        width: 30px;
    }

    100% {
        width: 0;
    }
}

@keyframes shooting {
    0% {
        transform: translateX(0) rotateZ(45deg);
    }

    100% {
        transform: translateX(300px) rotateZ(45deg);
    }
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.scroll-indicator span {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    opacity: 0.6;
}

.mouse {
    width: 25px;
    height: 40px;
    border: 2px solid var(--primary-color);
    border-radius: 20px;
    position: relative;
}

.mouse::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 50%;
    width: 4px;
    height: 8px;
    background: var(--primary-color);
    margin-left: -2px;
    border-radius: 2px;
    animation: mouse-scroll 2s infinite;
}

@keyframes mouse-scroll {
    0% {
        opacity: 1;
        transform: translateY(0);
    }

    100% {
        opacity: 0;
        transform: translateY(15px);
    }
}

/* Content Container - Single Flow */
.main-wrapper {
    position: relative;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Sections */
.section {
    padding: 60px 0;
    position: relative;
    width: 100%;
    margin: 0 auto;
    z-index: 5;
}

/* Glassmorphism Card */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 50px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4);
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.8s ease;
    opacity: 0;
    transform: translateY(30px);
}

/* Specific Two-Column Layout for Letter Section */
.letter-card {
    flex-direction: row !important;
    align-items: flex-start !important;
    text-align: left !important;
    gap: 40px;
}

.letter-card .card-content {
    flex: 1.5;
    padding-right: 20px;
    margin-bottom: 0px;
}

.letter-card .card-image {
    flex: 1;
    max-width: 400px;
    margin: 0;
}

/* Fallback if JS fails */
.no-js .glass-card,
.no-js .section-header {
    opacity: 1 !important;
    transform: none !important;
}

.glass-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.card-content {
    width: 100%;
    padding: 0;
    margin-bottom: 30px;
}

.card-image {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
}

.card-image img {
    max-width: 100%;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    transition: transform 0.4s ease;
    border: 1px solid var(--glass-border);
}

.card-image img:hover {
    transform: scale(1.03);
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
    width: 100%;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.section-header.visible {
    opacity: 1;
    transform: translateY(0);
}

.section-title {
    font-family: 'Playfair Display', serif;
    font-size: 2.8rem;
    color: var(--primary-color);
    margin-bottom: 10px;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 60%;
    height: 2px;
    background: var(--gold-gradient);
}

.center-title::after {
    left: 20%;
}

.italic-title {
    font-style: italic;
}

.section-sub {
    font-size: 1.1rem;
    opacity: 0.7;
    letter-spacing: 1px;
}

/* Letter Section specific */
.letter-card {
    align-items: flex-start;
}

.letter-intro {
    font-size: 1.3rem !important;
    font-weight: 500;
    color: var(--primary-color) !important;
}

.letter-signature {
    margin-top: 30px;
}

.sig-name {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem !important;
    font-weight: 700;
    margin-bottom: 5px;
}

.sig-role {
    font-size: 0.9rem !important;
    opacity: 0.6;
}

.portrait-img {
    border: 5px solid var(--glass-border) !important;
    width: 100%;
    height: auto;
    object-fit: cover;
}

/* Vision Grid */
.vision-grid {
    display: flex;
    flex-wrap: wrap;
    /* Flexibility to prevent overlap */
    justify-content: center;
    gap: 40px;
    width: 100%;
    margin: 40px 0;
}

.vision-grid .glass-card {
    flex: 1;
    min-width: 320px;
    max-width: 500px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 40px;
}

.card-img {
    height: 180px;
    margin-bottom: 20px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--glass-border);
}

.card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    margin-bottom: 12px;
}

.gold-text {
    color: var(--primary-color);
}

/* Ethics */
.ethics-items {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-top: 50px;
    flex-wrap: wrap;
    width: 100%;
}

.ethic-item {
    text-align: center;
    flex: 1;
    min-width: 250px;
    /* Increased to prevent squishing */
    max-width: 320px;
    margin-bottom: 30px;
}

.ethic-visual {
    width: 100px;
    height: 100px;
    margin: 0 auto 15px;
    position: relative;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid var(--primary-color);
}

.ethic-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.7);
}

.ethic-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-color);
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.8);
}

/* Services Grid */
.services-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
    width: 100%;
}

.service-card {
    flex: 1;
    min-width: 300px;
    max-width: 380px;
    padding: 30px !important;
    text-align: center;
    transition: all 0.4s ease;
    overflow: visible;
    /* Allow icons to pop */
}

.service-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: var(--primary-color);
}

.service-img-wrapper {
    width: 100%;
    height: 150px;
    margin-bottom: 20px;
    border-radius: 10px;
    overflow: hidden;
}

.service-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.service-card:hover .service-img {
    transform: scale(1.1);
}

.service-icon {
    font-size: 2.5rem;
    margin-top: -30px;
    background: var(--dark-bg);
    display: inline-block;
    padding: 5px 15px;
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    position: relative;
    z-index: 2;
}

/* Full Width Divider */
.parallax-divider {
    height: 400px;
    width: 100%;
    background-size: cover;
    background-attachment: fixed;
    background-position: center;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 50px 0;
}

.parallax-overlay {
    background: rgba(0, 0, 0, 0.6);
    padding: 20px 40px;
    border: 1px solid var(--primary-color);
    text-align: center;
}

.parallax-text {
    font-size: 2rem;
    font-weight: bold;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 3px;
}

/* Leadership Section */
.leadership-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 20px;
    width: 100%;
}

.leader-card {
    display: flex !important;
    flex-direction: column !important;
    /* Stack for centering */
    align-items: center;
    text-align: center !important;
    gap: 15px;
    padding: 30px !important;
}

.leader-img-wrapper {
    width: 90px;
    height: 90px;
    flex-shrink: 0;
    position: relative;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid var(--primary-color);
    background: #0a1628;
}

.leader-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
}

.leader-info h3 {
    margin: 0 0 5px;
    font-family: 'Playfair Display', serif;
    font-size: 1.2rem;
}

.leader-role {
    color: var(--primary-color);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 5px;
}

.leader-desc {
    font-size: 0.8rem;
    opacity: 0.8;
    line-height: 1.4;
    margin: 0;
}

/* Circular Process Redesign */
.circular-process {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 0;
    margin: 60px 0;
    flex-wrap: wrap;
    width: 100%;
}

.process-circle-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 200px;
    position: relative;
    padding: 20px;
}

.circle-visual {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    position: relative;
    border: 3px solid var(--primary-color);
    padding: 8px;
    background: var(--glass-bg);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    animation: rotateSlow 10s linear infinite;
    /* Continuous motion */
}

.process-circle-item:hover .circle-visual {
    transform: scale(1.1);
    box-shadow: 0 0 30px rgba(212, 175, 55, 0.6);
}

.circle-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    animation: counterRotate 10s linear infinite;
    /* Keep image vertical */
}

.circle-number {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 35px;
    height: 35px;
    background: var(--primary-color);
    color: var(--secondary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    z-index: 10;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.circle-content {
    margin-top: 20px;
}

.circle-content h3 {
    font-family: 'Playfair Display', serif;
    color: var(--primary-color);
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.circle-content p {
    font-size: 0.9rem;
    opacity: 0.8;
    line-height: 1.4;
}

.process-arrow {
    position: absolute;
    right: -25px;
    top: 70px;
    font-size: 2rem;
    color: var(--primary-color);
    opacity: 0.5;
    animation: arrowFlow 2s ease-in-out infinite;
}

@keyframes rotateSlow {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes counterRotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(-360deg);
    }
}

@keyframes arrowFlow {

    0%,
    100% {
        transform: translateX(0);
        opacity: 0.3;
    }

    50% {
        transform: translateX(10px);
        opacity: 0.8;
    }
}

/* Footer & Waves */
.footer {
    background: #000c22;
    padding: 80px 0 30px;
    /* Balanced padding */
    position: relative;
    overflow: hidden;
    z-index: 10;
}

.footer-waves {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 80px;
    /* More compact waves */
    pointer-events: none;
    z-index: 1;
    opacity: 0.3;
    /* More subtle */
}

.wave {
    position: absolute;
    top: 0;
    left: 0;
    width: 200%;
    height: 80px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 800 88.7'%3E%3Cpath d='M800 56.9c-155.5 0-204.9-50-405.5-49.9-200 0-250 49.9-394.5 49.9V0h800v56.9z' fill='%23002366'/%3E%3C/svg%3E");
    background-size: 1000px 80px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
    position: relative;
    z-index: 5;
}

.wave1 {
    z-index: 10;
    opacity: 1;
    animation: moveWave 30s linear infinite;
}

.wave2 {
    z-index: 8;
    opacity: 0.5;
    animation: moveWave 20s linear infinite reverse;
    top: -95px;
}

.wave3 {
    z-index: 6;
    opacity: 0.2;
    animation: moveWave 15s linear infinite;
    top: -90px;
}

.wave4 {
    z-index: 4;
    opacity: 0.7;
    animation: moveWave 10s linear infinite reverse;
    top: -85px;
}

@keyframes moveWave {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* Footer Blending Redesign */
.footer {
    background: linear-gradient(to bottom, transparent 0%, #000c22 100%);
    padding: 120px 0 40px;
    position: relative;
    overflow: hidden;
    z-index: 10;
}

.footer-logo {
    height: 100px;
    margin-bottom: 20px;
    filter: drop-shadow(0 0 15px rgba(212, 175, 55, 0.6));
    /* Logo Glow */
    transition: transform 0.3s ease;
}

.footer-logo:hover {
    transform: scale(1.05);
}

.footer-brand h3 {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    letter-spacing: 2px;
    margin-bottom: 10px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.footer-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 40px;
    text-align: left;
    margin: 60px 0;
}

.info-item p {
    font-size: 1rem;
    line-height: 1.6;
    color: #fff;
    text-shadow: 0 1px 5px rgba(0, 0, 0, 0.5);
}

/* Responsive Audit */
@media (max-width: 1024px) {
    .process-arrow {
        display: none;
        /* Hide arrows on small/vertical flow */
    }

    .process-circle-item {
        width: 100%;
        max-width: 400px;
    }
}

@media (max-width: 900px) {
    .main-wrapper {
        padding: 0 15px;
    }

    .glass-card {
        padding: 25px !important;
        /* Smaller padding for mobile */
    }

    .letter-card {
        flex-direction: column !important;
        text-align: center !important;
        gap: 30px;
    }

    .letter-card .card-content {
        padding-right: 0;
        width: 100%;
        margin-bottom: 20px;
    }

    .letter-card .card-image {
        max-width: 100%;
        width: 100%;
    }

    .ethics-items {
        gap: 20px;
    }

    .ethic-item {
        min-width: 100%;
        /* Full width on mobile to prevent overflow */
        max-width: 100%;
    }

    .vision-grid .glass-card {
        flex: 1 1 100%;
        max-width: 100%;
    }

    .services-grid {
        gap: 20px;
    }

    .service-card {
        min-width: 100%;
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .section-title {
        font-size: 1.6rem !important;
    }

    .hero-section h1 {
        font-size: 2rem !important;
    }

    .hero-slogan {
        font-size: 1.4rem !important;
    }

    .circle-visual {
        width: 100px;
        height: 100px;
    }

    .process-circle-item {
        padding: 10px;
    }
}

/* Animation Keyframes */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}