/* File: assets/css/hero-curve-slider.css */

.rub-hero-wrapper {
    position: relative;
    width: 100%;
/*     height: 105vh; */
    height: 1200px;
    min-height: 750px;
    overflow: hidden;
    font-family: "Montserrat", Sans-serif;
    background: #222;
}

/* SWIPER */
.rub-swiper { width: 100%; height: 100%; }
.rub-slide-item { width: 100%; height: 100%; background-size: contain !important; background-repeat: no-repeat !important; background-position: center; position: relative; }
/* .rub-slide-overlay { position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(0,0,0,0.1), rgba(0,0,0,0.6)); } */
.rub-slide-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 549px;
    background: linear-gradient(
        to bottom,
        rgba(160, 122, 67, 0) 0%, 
        rgba(88, 55, 19, 0.18) 21%, 
        rgba(88, 55, 19, 0.70) 42%, 
        #583713 61%
    );
    z-index: 1;
    pointer-events: none;
}

.rub-slide-content { 
	position: absolute; 
	top: 28%; 
	left: 50%; 
	transform: translate(-50%, -50%); 
	text-align: center; 
	color: #909DA2; 
	width: 80%; 
	z-index: 2; 
	pointer-events: none; 
	
	font-size: 18px;
	font-weight: 500;
}
.rub-slide-content a, .rub-slide-content button { pointer-events: auto; }

.slide-title {
			letter-spacing: -0.3px;
    		font-family: "El Messiri", Sans-serif !important;
    		font-size: clamp(2.5rem, 5vw, 4.5rem);
    		font-weight: 600;
    		margin-bottom: 15px;
    		color: #6ea8d6;

    		/* smooth thin border effect */
    		-webkit-text-stroke: 0.1px rgba(255,255,255,0.75);

    		/* soft professional depth */
    		text-shadow:
        		0 1px 0 rgba(255,255,255,0.65),
        		0 2px 0px rgba(255,255,255,0.35),
        		0 2px 0px rgba(0,0,0,0.14),
        		0 4px 18px rgba(0,0,0,0.10);
			}

.slide-desc {
    color: #4f5c64;
    text-shadow:
        0 1px 0 rgba(255,255,255,0.55),
        0 1px 6px rgba(255,255,255,0.18),
        0 2px 8px rgba(0,0,0,0.08);
}

/* 1. แก้ไขปุ่ม Hover ให้ทำงานทุกสไลด์ */
.rub-hero-wrapper .rub-btn {
    position: relative; /* สำคัญ: เพื่อให้ z-index ทำงาน */
    z-index: 50; /* ดันปุ่มให้ลอยเหนือทุกอย่าง */
    
    /* สไตล์ปุ่มเดิม */
    display: inline-block;
    padding: 12px 35px;
    border: 3px solid #97C3E8;
    border-radius: 50px;
    color: #A07A43;
    background-color: #ffffff;
    text-decoration: none;
    font-weight: 600;
    margin-top: 20px;
    transition: all 0.3s;
    font-family: "El Messiri", sans-serif !important;
    font-size: 18px;
    line-height: 18px;
    
    /* เงา 2 ชั้น (Gap ขาว + ขอบน้ำตาล) */
    box-shadow: 0 0 0 3px #ffffff, 0 0 0 4px #A07A43;
}

/* Hover Effect */
.rub-hero-wrapper .rub-btn:hover {
    background-color: #97C3E8 !important;
    color: #ffffff !important;
    border-color: #96c3e880 !important;
/*     box-shadow: 0 0 0 3px #ffffff, 0 0 0 4px #97C3E8; */
}

.rub-swiper .swiper-slide {
    z-index: 1;
    pointer-events: none;
}

.rub-swiper .swiper-slide-active {
    z-index: 10;
    pointer-events: auto;
}

.rub-slide-content {
    pointer-events: none; 
}
.rub-slide-content a, 
.rub-slide-content button {
    pointer-events: auto;
}



/* --- CURVE CONTAINER --- */
/* ส่วนนี้จะถูก JS/PHP ควบคุมความสูง (Default 150px) */
.rub-curve-container {
    position: absolute;
    bottom: 150px; /* ค่า Default */
    left: 0;
    width: 100%;
    /* Height กำหนดใน PHP Control */
    height: 150px; 
    pointer-events: none;
    z-index: 10;
}

.rub-line-wrapper {
    position: relative;
    width: 100%;
    height: 120%;
    pointer-events: none;
}

.rub-line-svg {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    overflow: visible;
    z-index: 1;
}

.progress-line {
    transition: stroke-dashoffset 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* --- NAV ITEMS --- */
.rub-nav-items {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 20;
    pointer-events: none;
}

.rub-nav-item {
    position: absolute;
    /* เริ่มที่ (0,0) ของ Container แล้ว JS จะสั่ง top/left เอง */
    top: 0; left: 0; 
    width: 0; height: 0;
    pointer-events: auto;
    cursor: pointer;
    overflow: visible;
}

.nav-dot-wrapper {
    position: absolute;
    transform: translate(-50%, -50%); /* ดึงให้จุดกึ่งกลางอยู่ตรงพิกัดเป๊ะ */
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-dot {
    width: 14px;
    height: 14px;
    background-color: #fff;
    border-radius: 50%;
    transition: all 0.3s;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
}

.nav-label {
    position: absolute;
    top: 25px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 14px;
    color: rgba(255,255,255,0.7);
/*     text-transform: uppercase; */
    font-weight: 500;
    white-space: nowrap;
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
    transition: 0.3s;
    pointer-events: none;
	text-align:center;
}

/* Active & Hover */
.rub-nav-item.active .nav-dot {
    background-color: #97C3E8;
    transform: scale(1.5);
    box-shadow: 0 0 0 5px rgba(151, 195, 232, 0.4);
}
.rub-nav-item.active .nav-label { color: #fff; top: 30px; }
.rub-nav-item:hover .nav-label { color: #fff; }

@media (max-width: 768px) {
    .rub-hero-wrapper { height: 70vh; min-height: 500px; }
    /* Mobile Adjustments */
    .rub-curve-container { bottom: 80px !important; height: 100px !important; }
    .nav-dot { width: 10px; height: 10px; }
    .nav-label { font-size: 11px; top: 20px; }
	.rub-slide-item {
        background-size: cover !important;
        background-position: center center !important;
    }
}