/**
 * Portfolio Page Styles - CUSTOM DESIGN
 * Based on client specifications:
 * - Countries: Flag pills
 * - Industries: Compact cards side by side
 * - Tools: Panel grid layout
 */

/* ==================== CSS VARIABLES ==================== */
:root {
    --dark: #0A0E1A;
    --dark-light: #1E2637;
    --primary: #FF9500;
    --primary-hover: #FFB340;
    --text: #FFFFFF;
    --text-light: #E5E5E5;
    --text-gray: #94A3B8;
    --border: rgba(255, 255, 255, 0.1);
    --border-primary: rgba(255, 149, 0, 0.4);
}

/* ==================== PORTFOLIO HERO SECTION ==================== */

.portfolio-hero-section {
    background: linear-gradient(135deg, 
        #0F1624 0%, 
        #1a2332 25%,
        #0d1520 50%,
        #1f2937 75%,
        #0F1624 100%
    );
    position: relative;
    padding: 160px 0 100px;
    overflow: hidden;
    min-height: 60vh;
}

.portfolio-hero-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, rgba(255, 149, 0, 0.08) 0%, transparent 70%);
    z-index: 1;
}

.portfolio-hero-section::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(rgba(255, 149, 0, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 149, 0, 0.04) 1px, transparent 1px);
    background-size: 80px 80px;
    z-index: 1;
    opacity: 0.6;
}

.portfolio-hero-section .container {
    position: relative;
    z-index: 10;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.portfolio-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 28px;
    background: rgba(255, 149, 0, 0.06);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 149, 0, 0.4);
    border-radius: 50px;
    margin-bottom: 30px;
    box-shadow: 
        0 0 25px rgba(255, 149, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
    animation: fadeIn 0.8s ease-out;
}

.portfolio-badge span {
    color: #FF9500;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.portfolio-hero-title {
    font-size: clamp(48px, 6vw, 72px);
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 24px;
    letter-spacing: -2px;
    color: #FFFFFF;
    animation: fadeIn 0.8s ease-out 0.2s backwards;
}

.portfolio-hero-title .text-primary {
    color: #FF9500;
}

.portfolio-hero-subtitle {
    font-size: 20px;
    line-height: 1.6;
    color: #E5E5E5;
    max-width: 700px;
    margin: 0 auto;
    animation: fadeIn 0.8s ease-out 0.4s backwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==================== PORTFOLIO SECTIONS ==================== */

.portfolio-section {
    background: linear-gradient(180deg, 
        rgba(15, 22, 36, 0.95) 0%, 
        rgba(25, 32, 48, 0.98) 50%,
        rgba(15, 22, 36, 0.95) 100%
    );
    position: relative;
    padding: 120px 0;
    overflow: hidden;
}

.portfolio-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, rgba(255, 149, 0, 0.06) 0%, transparent 70%);
    z-index: 1;
}

.portfolio-section::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 150px;
    background: linear-gradient(to bottom, transparent, rgba(20, 25, 35, 0.4));
    pointer-events: none;
    z-index: 2;
}

.portfolio-section.alternate {
    background: linear-gradient(180deg, 
        rgba(18, 24, 38, 0.95) 0%, 
        rgba(22, 28, 42, 0.98) 50%,
        rgba(18, 24, 38, 0.95) 100%
    );
}

.section-container {
    position: relative;
    z-index: 10;
    max-width: 1400px;
    width: 90%;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 80px;
}

.section-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: rgba(255, 149, 0, 0.07);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 149, 0, 0.4);
    border-radius: 50px;
    font-size: 12px;
    font-weight: 700;
    color: #FF9500;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 3px;
    box-shadow: 
        0 0 25px rgba(255, 149, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.section-title {
    font-size: 60px;
    font-weight: 800;
    color: #FFFFFF;
    margin-bottom: 20px;
    letter-spacing: -2px;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 4px;
    background: linear-gradient(90deg, #FF9500 0%, #FFB340 100%);
    border-radius: 2px;
}

.section-subtitle {
    font-size: 18px;
    color: #94A3B8;
    font-weight: 400;
    margin-top: 10px;
}

/* ==================== COUNTRIES - FLAG PILLS ==================== */

.pills-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

.pill-item {
    padding: 14px 26px;
    background: rgba(30, 38, 55, 0.6);
    border: 2px solid rgba(255, 149, 0, 0.35);
    border-radius: 30px;
    font-size: 15px;
    font-weight: 600;
    color: #FFFFFF;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    white-space: nowrap;
    box-shadow: 
        0 4px 12px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.pill-item:hover {
    border-color: #FF9500;
    background: rgba(255, 149, 0, 0.15);
    transform: translateY(-3px);
    color: #FF9500;
    box-shadow: 
        0 8px 25px rgba(255, 149, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.pill-emoji {
    margin-right: 8px;
    font-size: 1.2em;
}

/* ==================== INDUSTRIES - COMPACT CARDS ==================== */

.icons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.icon-item {
    background: linear-gradient(135deg, rgba(30, 38, 55, 0.7), rgba(30, 38, 55, 0.85));
    border: 2px solid rgba(255, 149, 0, 0.3);
    border-radius: 16px;
    padding: 30px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    min-height: 140px;
    box-shadow: 
        0 6px 18px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.icon-item:hover {
    border-color: #FF9500;
    background: linear-gradient(135deg, rgba(255, 149, 0, 0.12), rgba(30, 38, 55, 0.9));
    transform: translateY(-5px);
    box-shadow: 
        0 12px 30px rgba(255, 149, 0, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.icon-symbol {
    font-size: 44px;
    filter: drop-shadow(0 4px 12px rgba(255, 149, 0, 0.4));
}

.icon-label {
    font-size: 14px;
    font-weight: 700;
    color: #FFFFFF;
    text-align: center;
    line-height: 1.3;
}

.icon-item:hover .icon-label {
    color: #FF9500;
}

/* ==================== TOOLS - PANEL GRID ==================== */

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 25px;
    max-width: 1400px;
    margin: 0 auto;
}

.tool-category {
    background: rgba(30, 38, 55, 0.7);
    border: 2px solid rgba(255, 149, 0, 0.3);
    border-radius: 20px;
    padding: 30px 28px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    box-shadow: 
        0 8px 25px rgba(0, 0, 0, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.tool-category:hover {
    border-color: #FF9500;
    background: rgba(30, 38, 55, 0.85);
    transform: translateY(-6px);
    box-shadow: 
        0 15px 40px rgba(255, 149, 0, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.tool-category h4 {
    color: #FF9500;
    font-size: 22px;
    font-weight: 800;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 15px;
    border-bottom: 2px solid rgba(255, 149, 0, 0.2);
}

.tool-category h4 span {
    font-size: 28px;
    filter: drop-shadow(0 2px 8px rgba(255, 149, 0, 0.5));
}

.tool-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tool-tag {
    background: rgba(255, 149, 0, 0.15);
    color: #FFB340;
    padding: 10px 18px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    border: 1px solid rgba(255, 149, 0, 0.35);
    transition: all 0.2s ease;
    white-space: nowrap;
}

.tool-tag:hover {
    background: rgba(255, 149, 0, 0.25);
    color: #FF9500;
    border-color: #FF9500;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 149, 0, 0.3);
}

/* ==================== PARTNERS CAROUSEL ==================== */

.partners-section {
    background: linear-gradient(180deg, 
        rgba(15, 22, 36, 0.95) 0%, 
        rgba(20, 28, 42, 0.98) 50%,
        rgba(15, 22, 36, 0.95) 100%
    );
    position: relative;
    padding: 120px 0;
    overflow: hidden;
}

.partners-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, rgba(255, 149, 0, 0.05) 0%, transparent 70%);
    z-index: 1;
}

.partners-wrapper {
    overflow: hidden;
    padding: 40px 0;
    position: relative;
}

.partners-wrapper::before,
.partners-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 150px;
    z-index: 10;
    pointer-events: none;
}

.partners-wrapper::before {
    left: 0;
    background: linear-gradient(to right, rgba(20, 28, 42, 0.98), transparent);
}

.partners-wrapper::after {
    right: 0;
    background: linear-gradient(to left, rgba(20, 28, 42, 0.98), transparent);
}

.partners-grid {
    display: inline-flex;
    gap: 35px;
    animation: scroll-partners 40s linear infinite;
    will-change: transform;
}

.partners-grid:hover {
    animation-play-state: paused;
}

@keyframes scroll-partners {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

.partner-card {
    flex: 0 0 280px;
    width: 280px;
    height: 160px;
    background: #FFFFFF;
    border-radius: 25px;
    padding: 45px 55px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow: 
        0 10px 30px rgba(0, 0, 0, 0.3),
        0 0 20px rgba(255, 149, 0, 0.08);
}

.partner-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 149, 0, 0.2), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.partner-card:hover {
    transform: translateY(-10px);
    box-shadow: 
        0 25px 50px rgba(0, 0, 0, 0.4),
        0 0 45px rgba(255, 149, 0, 0.1);
}

.partner-card:hover::before {
    opacity: 1;
}

.partner-card a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    text-decoration: none;
}

.partner-logo {
    max-width: 180px;
    width: 100%;
    height: 70px;
    object-fit: contain;
    filter: grayscale(100%) brightness(0.4);
    opacity: 0.7;
    transition: all 0.4s ease;
}

.partner-card:hover .partner-logo {
    filter: grayscale(0%) brightness(1);
    opacity: 1;
    transform: scale(1.1);
}

/* ==================== EXPERTISE GRID ==================== */

.expertise-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

.expertise-card {
    position: relative;
    background: linear-gradient(
        135deg,
        rgba(255, 149, 0, 0.05) 0%,
        rgba(30, 38, 55, 0.7) 50%,
        rgba(255, 149, 0, 0.05) 100%
    );
    border: 2px solid rgba(255, 149, 0, 0.45);
    border-radius: 25px;
    padding: 35px 30px;
    backdrop-filter: blur(15px);
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    box-shadow: 
        0 10px 35px rgba(0, 0, 0, 0.4),
        0 0 25px rgba(255, 149, 0, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.expertise-card::before {
    content: '';
    position: absolute;
    top: 20px;
    right: 20px;
    width: 35px;
    height: 35px;
    border-top: 2px solid rgba(255, 149, 0, 0.5);
    border-right: 2px solid rgba(255, 149, 0, 0.5);
    transition: all 0.3s ease;
}

.expertise-card:hover {
    border-color: #FF9500;
    background: linear-gradient(
        135deg,
        rgba(255, 149, 0, 0.06) 0%,
        rgba(30, 38, 55, 0.85) 50%,
        rgba(255, 149, 0, 0.06) 100%
    );
    transform: translateY(-8px);
    box-shadow: 
        0 20px 45px rgba(0, 0, 0, 0.5),
        0 0 45px rgba(255, 149, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.expertise-card:hover::before {
    border-color: #FF9500;
}

.expertise-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.expertise-number {
    font-size: 56px;
    font-weight: 900;
    color: transparent;
    -webkit-text-stroke: 2px #FF9500;
    line-height: 1;
}

.expertise-icon {
    font-size: 48px;
    filter: drop-shadow(0 4px 10px rgba(255, 149, 0, 0.4));
}

.expertise-title {
    font-size: 24px;
    font-weight: 900;
    color: #FFFFFF;
    margin-bottom: 25px;
    line-height: 1.2;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.expertise-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.expertise-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    color: #D0D0D0;
    transition: all 0.3s ease;
    font-weight: 500;
}

.expertise-list li:before {
    content: '';
    width: 8px;
    height: 8px;
    background: #FF9500;
    border-radius: 50%;
    flex-shrink: 0;
    box-shadow: 0 0 10px rgba(255, 149, 0, 0.6);
    transition: all 0.3s ease;
}

.expertise-list li:hover {
    color: #FFFFFF;
    transform: translateX(5px);
}

.expertise-list li:hover:before {
    transform: scale(1.3);
    box-shadow: 0 0 15px rgba(255, 149, 0, 0.8);
}

/* ==================== CTA SECTION ==================== */

.cta-section {
    background: linear-gradient(180deg, 
        rgba(15, 22, 36, 0.95) 0%, 
        rgba(18, 25, 38, 0.98) 50%,
        rgba(15, 22, 36, 0.95) 100%
    );
    position: relative;
    padding: 120px 0;
    overflow: hidden;
    border-top: 1px solid rgba(255, 149, 0, 0.3);
}

/* ==================== RESPONSIVE ==================== */

@media (max-width: 1024px) {
    .expertise-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .tools-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .icons-grid {
    }
}

@media (max-width: 768px) {
    .portfolio-hero-section {
        padding: 120px 0 80px;
    }
    
    .portfolio-hero-title {
        font-size: 42px;
    }
    
    .section-title {
        font-size: 40px;
    }
    
    .expertise-grid {
        grid-template-columns: 1fr;
    }
    
    .tools-grid {
        grid-template-columns: 1fr;
    }
    
    .icons-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .partner-card {
        flex: 0 0 220px;
        width: 220px;
    }
}

@media (max-width: 480px) {
    .portfolio-hero-section {
        padding: 80px 0 60px;
        min-height: 35vh;
    }
    
    .portfolio-hero-title {
        font-size: 36px;
    }
    
    .section-title {
        font-size: 32px;
    }
    
    }

@media (max-width: 768px) {
    .partners-section {
        padding: 60px 0 30px;
    }
}

@media (max-width: 768px) {
    .portfolio-section {
        padding: 30px 0 30px;
    }
}

@media (max-width: 768px) {
    .pills-grid {
        display: flex;
        flex-wrap: wrap;
        justify-content: space-evenly;
    }
}
/* ==================== ACCESSIBILITY ==================== */

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .partners-grid {
        animation-duration: 80s !important;
    }
}