/* =========================================================
   RIPL India Showcase - Complete Stylesheet
   ========================================================= */

/* ---- Reset & Base ---- */
.ripl-showcase-wrap *,
.ripl-showcase-wrap *::before,
.ripl-showcase-wrap *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

.ripl-showcase-wrap {
    position: relative;
    width: 100%;
    overflow: hidden;
    background: linear-gradient(135deg, #0a1628 0%, #0d2461 50%, #0a1628 100%);
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    --ripl-accent: #c9a227;
    --ripl-blue: #1a56db;
    --ripl-glow: #1a56db;
    --ripl-text: #ffffff;
    --ripl-text-muted: #c8d8f0;
}

/* ---- Corner Accents ---- */
.ripl-corner-tl,
.ripl-corner-br {
    position: absolute;
    width: 80px;
    height: 80px;
    z-index: 10;
    pointer-events: none;
}

.ripl-corner-tl {
    top: 0; left: 0;
    border-top: 3px solid var(--ripl-accent);
    border-left: 3px solid var(--ripl-accent);
}

.ripl-corner-br {
    bottom: 0; right: 0;
    border-bottom: 3px solid var(--ripl-accent);
    border-right: 3px solid var(--ripl-accent);
}

/* ========================================================
   HEADER
   ======================================================== */
.ripl-header {
    background: linear-gradient(180deg, rgba(5,15,40,0.98) 0%, rgba(10,22,65,0.92) 100%);
    padding: 22px 40px;
    position: relative;
    z-index: 5;
}

.ripl-header-inner {
    display: flex;
    align-items: center;
    justify-content: center;
}

.ripl-logo-group {
    display: flex;
    align-items: center;
    gap: 20px;
}

.ripl-logo img {
    width: 80px;
    height: auto;
    display: block;
    filter: drop-shadow(0 0 8px rgba(74,158,255,0.5));
    transition: filter 0.3s ease;
}

.ripl-logo-text .ripl-logo-icon svg text {
    letter-spacing: 1px;
}

.ripl-header-divider {
    width: 2px;
    height: 60px;
    background: linear-gradient(to bottom, transparent, var(--ripl-text-muted), transparent);
    opacity: 0.6;
}

.ripl-header-text {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.ripl-company-name {
    font-size: clamp(1.6rem, 3.5vw, 2.8rem);
    font-weight: 800;
    color: #4a9eff;
    letter-spacing: 0.02em;
    line-height: 1.1;
    text-shadow: 0 0 30px rgba(74,158,255,0.4);
}

.ripl-tagline {
    font-size: clamp(0.65rem, 1.2vw, 0.85rem);
    font-weight: 400;
    color: var(--ripl-text-muted);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    position: relative;
    padding-bottom: 8px;
}

.ripl-tagline::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 80%;
    height: 1px;
    background: var(--ripl-accent);
}

/* ========================================================
   SERVICES ROW
   ======================================================== */
.ripl-services-row {
    display: flex;
    width: 100%;
    gap: 3px;
    position: relative;
}

/* ---- Service Card ---- */
.ripl-service-card {
    position: relative;
    flex: 1;
    height: 320px;
    overflow: hidden;
    cursor: pointer;
    background-image: var(--card-bg);
    background-size: cover;
    background-position: center;
    background-color: #0a2060;
    transition: flex 0.45s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.35s ease,
                box-shadow 0.35s ease;
}

/* Default placeholder gradient if no image */
.ripl-service-card:nth-child(1) { background-color: #0d1a3a; }
.ripl-service-card:nth-child(2) { background-color: #0a1830; }
.ripl-service-card:nth-child(3) { background-color: #0d2040; }
.ripl-service-card:nth-child(4) { background-color: #0a1f38; }
.ripl-service-card:nth-child(5) { background-color: #0d1e35; }

/* Overlay */
.ripl-card-overlay {
    position: absolute;
    inset: 0;
    background: rgba(5,20,60,0.55);
    z-index: 1;
    transition: background 0.35s ease;
}

/* Shine sweep */
.ripl-card-shine {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent 30%, rgba(255,255,255,0.06) 50%, transparent 70%);
    z-index: 2;
    transform: translateX(-100%);
    transition: transform 0.6s ease;
    pointer-events: none;
}

/* Card Content */
.ripl-card-content {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-end;
    padding: 20px 18px 24px;
    gap: 8px;
}

/* Icon */
.ripl-service-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--ripl-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: #fff;
    box-shadow: 0 4px 20px rgba(26, 86, 219, 0.6);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
    flex-shrink: 0;
    margin-bottom: 4px;
}

/* Title */
.ripl-service-title {
    font-size: clamp(0.7rem, 1.1vw, 0.95rem);
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    line-height: 1.25;
    position: relative;
    padding-bottom: 6px;
}

.ripl-service-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 30px;
    height: 2px;
    background: var(--ripl-accent);
    transition: width 0.35s ease;
}

/* Description */
.ripl-service-desc {
    font-size: clamp(0.62rem, 0.9vw, 0.8rem);
    color: var(--ripl-text-muted);
    line-height: 1.4;
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

/* Border glow bottom */
.ripl-card-border-glow {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--ripl-glow, #1a56db);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
    z-index: 4;
}

/* ========================================================
   HOVER EFFECTS
   ======================================================== */

/* --- zoom --- */
.ripl-hover-zoom .ripl-service-card:hover {
    transform: scale(1.03);
    z-index: 10;
}

/* --- zoom-glow (default) --- */
.ripl-hover-zoom-glow .ripl-service-card:hover {
    transform: scale(1.025);
    z-index: 10;
    box-shadow: 0 0 30px rgba(26,86,219,0.7), 0 0 60px rgba(26,86,219,0.3);
}

.ripl-hover-zoom-glow .ripl-service-card:hover .ripl-card-overlay {
    background: rgba(5,20,80,0.35);
}

.ripl-hover-zoom-glow .ripl-service-card:hover .ripl-service-icon {
    transform: scale(1.15) translateY(-3px);
    box-shadow: 0 6px 30px rgba(26, 86, 219, 0.9);
}

.ripl-hover-zoom-glow .ripl-service-card:hover .ripl-service-title::after {
    width: 100%;
}

.ripl-hover-zoom-glow .ripl-service-card:hover .ripl-card-border-glow {
    transform: scaleX(1);
}

/* --- lift --- */
.ripl-hover-lift .ripl-service-card:hover {
    transform: translateY(-8px);
    z-index: 10;
    box-shadow: 0 20px 40px rgba(0,0,10,0.6);
}

.ripl-hover-lift .ripl-service-card:hover .ripl-card-border-glow {
    transform: scaleX(1);
}

/* --- tilt 3D --- */
.ripl-hover-tilt .ripl-service-card {
    transform-style: preserve-3d;
    perspective: 600px;
}

.ripl-hover-tilt .ripl-service-card:hover {
    transform: perspective(600px) rotateY(-6deg) rotateX(3deg) scale(1.02);
    z-index: 10;
}

/* --- shimmer --- */
.ripl-hover-shimmer .ripl-service-card:hover .ripl-card-shine {
    transform: translateX(100%);
}

.ripl-hover-shimmer .ripl-service-card:hover .ripl-card-border-glow {
    transform: scaleX(1);
}

/* --- slide-up reveal --- */
.ripl-hover-slide-up .ripl-service-desc {
    transform: translateY(10px);
    opacity: 0;
    transition: transform 0.35s ease, opacity 0.35s ease;
}

.ripl-hover-slide-up .ripl-service-card:hover .ripl-service-desc {
    transform: translateY(0);
    opacity: 1;
}

.ripl-hover-slide-up .ripl-service-card:hover .ripl-service-icon {
    transform: translateY(-5px);
}

.ripl-hover-slide-up .ripl-service-card:hover .ripl-card-border-glow {
    transform: scaleX(1);
}

/* --- border-glow only --- */
.ripl-hover-border-glow .ripl-service-card:hover {
    box-shadow: inset 0 0 0 2px var(--ripl-glow, #1a56db), 0 0 25px rgba(26,86,219,0.5);
}

.ripl-hover-border-glow .ripl-service-card:hover .ripl-card-border-glow {
    transform: scaleX(1);
}

/* ========================================================
   VALUES BAR
   ======================================================== */
.ripl-values-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    background: rgba(10,22,60,0.95);
    padding: 18px 40px;
    gap: 0;
    border-top: 1px solid rgba(255,255,255,0.08);
}

.ripl-val-item {
    flex: 1;
    min-width: 150px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 8px 16px;
    position: relative;
    transition: background 0.3s ease;
}

.ripl-val-item:not(:last-child) {
    border-right: 1px solid rgba(255,255,255,0.12);
}

.ripl-val-item:hover {
    background: rgba(255,255,255,0.04);
    border-radius: 8px;
}

.ripl-val-icon {
    font-size: 1.6rem;
    color: var(--ripl-accent);
    flex-shrink: 0;
    filter: drop-shadow(0 0 6px rgba(201,162,39,0.5));
    transition: transform 0.3s ease;
}

.ripl-val-item:hover .ripl-val-icon {
    transform: scale(1.2) rotate(-5deg);
}

.ripl-val-text {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.ripl-val-title {
    font-size: clamp(0.6rem, 0.9vw, 0.75rem);
    font-weight: 800;
    color: var(--ripl-accent);
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.ripl-val-desc {
    font-size: clamp(0.58rem, 0.8vw, 0.7rem);
    color: var(--ripl-text-muted);
    line-height: 1.4;
}

/* ========================================================
   ENTRY ANIMATIONS
   ======================================================== */

/* Initial hidden state */
.ripl-animate {
    opacity: 0;
}

/* fadeInUp */
@keyframes ripl-fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* fadeInDown */
@keyframes ripl-fadeInDown {
    from { opacity: 0; transform: translateY(-30px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* fadeInLeft */
@keyframes ripl-fadeInLeft {
    from { opacity: 0; transform: translateX(-30px); }
    to   { opacity: 1; transform: translateX(0); }
}

/* fadeInRight */
@keyframes ripl-fadeInRight {
    from { opacity: 0; transform: translateX(30px); }
    to   { opacity: 1; transform: translateX(0); }
}

/* zoomIn */
@keyframes ripl-zoomIn {
    from { opacity: 0; transform: scale(0.85); }
    to   { opacity: 1; transform: scale(1); }
}

/* slideInUp */
@keyframes ripl-slideInUp {
    from { opacity: 0; transform: translateY(60px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* flipInX */
@keyframes ripl-flipInX {
    from { opacity: 0; transform: perspective(400px) rotateX(-90deg); }
    to   { opacity: 1; transform: perspective(400px) rotateX(0); }
}

/* bounceIn */
@keyframes ripl-bounceIn {
    0%   { opacity: 0; transform: scale(0.5); }
    60%  { opacity: 1; transform: scale(1.05); }
    80%  { transform: scale(0.97); }
    100% { opacity: 1; transform: scale(1); }
}

/* Active animation classes */
.ripl-animate.ripl-anim-active { animation-duration: 0.65s; animation-fill-mode: both; animation-timing-function: cubic-bezier(0.25, 0.46, 0.45, 0.94); }
.ripl-anim-fadeInUp    { animation-name: ripl-fadeInUp; }
.ripl-anim-fadeInDown  { animation-name: ripl-fadeInDown; }
.ripl-anim-fadeInLeft  { animation-name: ripl-fadeInLeft; }
.ripl-anim-fadeInRight { animation-name: ripl-fadeInRight; }
.ripl-anim-zoomIn      { animation-name: ripl-zoomIn; }
.ripl-anim-slideInUp   { animation-name: ripl-slideInUp; }
.ripl-anim-flipInX     { animation-name: ripl-flipInX; }
.ripl-anim-bounceIn    { animation-name: ripl-bounceIn; animation-timing-function: ease-out; }
.ripl-anim-none        { opacity: 1; }

/* ========================================================
   PARALLAX
   ======================================================== */
.ripl-parallax-enabled .ripl-service-card {
    overflow: hidden;
}

/* ========================================================
   LAYOUT VARIANTS
   ======================================================== */

/* Auto layout */
.ripl-layout-auto .ripl-services-row {
    flex-direction: row;
}

/* Vertical layout */
.ripl-layout-vertical .ripl-services-row {
    flex-direction: column;
}

.ripl-layout-vertical .ripl-service-card {
    width: 100%;
    flex: none;
    height: auto;
    min-height: 160px;
}

.ripl-layout-vertical .ripl-card-content {
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    padding: 20px 24px;
    gap: 20px;
}

.ripl-layout-vertical .ripl-service-title::after {
    display: none;
}

.ripl-layout-vertical .ripl-service-icon {
    width: 70px;
    height: 70px;
    font-size: 1.8rem;
    flex-shrink: 0;
}

/* ========================================================
   MOBILE RESPONSIVE
   ======================================================== */
@media (max-width: 1024px) {
    .ripl-service-card {
        height: 260px;
    }

    .ripl-header {
        padding: 18px 24px;
    }

    .ripl-values-bar {
        padding: 14px 20px;
    }
}

@media (max-width: 768px) {

    /* Header stacks vertically */
    .ripl-header {
        padding: 20px 20px;
    }

    .ripl-logo-group {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 12px;
    }

    .ripl-header-divider {
        width: 60px;
        height: 2px;
    }

    .ripl-header-text {
        align-items: center;
    }

    .ripl-tagline::after {
        left: 50%;
        transform: translateX(-50%);
    }

    /* Services become vertical stack */
    .ripl-layout-auto .ripl-services-row,
    .ripl-layout-horizontal .ripl-services-row {
        flex-direction: column;
        gap: 2px;
    }

    .ripl-layout-auto .ripl-service-card,
    .ripl-layout-horizontal .ripl-service-card {
        width: 100%;
        flex: none;
        height: auto;
        min-height: 170px;
    }

    .ripl-layout-auto .ripl-card-content,
    .ripl-layout-horizontal .ripl-card-content {
        flex-direction: row;
        align-items: center;
        padding: 18px 20px;
        gap: 16px;
        justify-content: flex-start;
    }

    .ripl-layout-auto .ripl-service-title::after,
    .ripl-layout-horizontal .ripl-service-title::after {
        display: none;
    }

    .ripl-layout-auto .ripl-service-icon,
    .ripl-layout-horizontal .ripl-service-icon {
        width: 60px;
        height: 60px;
        font-size: 1.6rem;
        flex-shrink: 0;
    }

    /* Values bar: 2 columns or wraps */
    .ripl-values-bar {
        padding: 16px 16px;
    }

    .ripl-val-item {
        flex: 0 0 50%;
        min-width: 0;
        padding: 10px 12px;
        border-right: none !important;
        border-bottom: 1px solid rgba(255,255,255,0.08);
    }

    .ripl-val-item:nth-child(odd) {
        border-right: 1px solid rgba(255,255,255,0.08) !important;
    }

    .ripl-val-item:nth-last-child(-n+2) {
        border-bottom: none;
    }

    /* Disable 3D tilt on mobile */
    .ripl-hover-tilt .ripl-service-card:hover {
        transform: none;
    }
}

@media (max-width: 480px) {
    .ripl-company-name {
        font-size: 1.4rem;
    }

    .ripl-tagline {
        font-size: 0.6rem;
    }

    .ripl-service-title {
        font-size: 0.8rem;
    }

    .ripl-service-desc {
        font-size: 0.7rem;
    }

    .ripl-val-item {
        flex: 0 0 100%;
        border-right: none !important;
        border-bottom: 1px solid rgba(255,255,255,0.08) !important;
    }

    .ripl-val-item:last-child {
        border-bottom: none !important;
    }

    .ripl-corner-tl, .ripl-corner-br {
        width: 40px;
        height: 40px;
    }
}

/* ========================================================
   SCROLLBAR (optional)
   ======================================================== */
.ripl-showcase-wrap::-webkit-scrollbar { height: 4px; }
.ripl-showcase-wrap::-webkit-scrollbar-track { background: #0a1628; }
.ripl-showcase-wrap::-webkit-scrollbar-thumb { background: var(--ripl-blue); border-radius: 2px; }
