/* Import Modern Fonts */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,500;1,9..40,300&family=Urbanist:wght@300;500;700&display=swap');

:root {
    --primary: #004F63;    /* Ionian Teal */
    --accent: #8A9A5B;     /* Olive Grove */
    --bg: #FDFCF8;         /* Creamy Sand */
    --white: #ffffff;
    --text: #1a1a1a;
    --radius: 20px;        /* Modern Rounded Corners */
    --shadow: 0 10px 30px rgba(0,0,0,0.04);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'DM Sans', sans-serif;
    background-color: var(--bg);
    color: var(--text);
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
    font-family: 'Urbanist', sans-serif;
    font-weight: 500;
    letter-spacing: -0.02em;
}

/* --- Clean Navigation --- */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 8%;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px); /* Modern Glass Effect */
    position: sticky;
    top: 0;
    z-index: 1000;
}

.logo {
    font-family: 'Urbanist', sans-serif;
    font-weight: 700;
    font-size: 1.4rem;
    color: var(--primary);
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.nav-links a {
    margin-left: 30px;
    text-decoration: none;
    color: var(--text);
    font-weight: 500;
    font-size: 0.9rem;
    transition: 0.3s;
}

.nav-links a:hover {
    color: var(--accent);
}

/* --- Hero Section --- */
.hero {
    height: 75vh;
    margin: 0 20px; /* Slight margin to let the rounded corners of the background show */
    border-radius: var(--radius);
    background: linear-gradient(rgba(0,0,0,0.2), rgba(0,0,0,0.2)), 
                url('../media/hero-cover1.jpg') center/cover;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    text-align: center;
}

.hero h1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    margin-bottom: 15px;
}

/* --- Modern Card Grid --- */
.container {
    width: 85%;
    max-width: 1300px;
    margin: 80px auto;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
}

.card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 12px; /* Inner padding for the card container */
    box-shadow: var(--shadow);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    text-decoration: none;
    color: inherit;
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

.card-img {
    height: 280px;
    border-radius: calc(var(--radius) - 4px); /* Slightly smaller radius for the nested image */
    background-size: cover;
    background-position: center;
    margin-bottom: 20px;
}

.card-content {
    padding: 10px 15px 20px;
}

.card-tag {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--accent);
    letter-spacing: 1.5px;
    margin-bottom: 8px;
    display: block;
}

.card h3 {
    font-size: 1.6rem;
    margin-bottom: 10px;
    color: var(--primary);
}

/* --- Rounded Buttons --- */
.btn {
    display: inline-block;
    padding: 14px 32px;
    background: var(--primary);
    color: white;
    text-decoration: none;
    border-radius: 50px; /* Fully pill-shaped */
    font-weight: 500;
    transition: 0.3s;
    border: none;
}

.btn:hover {
    background: var(--accent);
    transform: scale(1.05);
}

footer {
    padding: 60px 8%;
    background: var(--white);
    text-align: center;
    border-top-left-radius: 40px;
    border-top-right-radius: 40px;
}

/* --- Villa Template Specifics --- */

.villa-header {
    padding-top: 40px;
    text-align: left;
}

.villa-meta {
    display: flex;
    gap: 20px;
    margin: 20px 0;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--primary);
}

.villa-meta span {
    background: white;
    padding: 8px 16px;
    border-radius: 50px;
    box-shadow: var(--shadow);
}

/* Photo Gallery Grid */
.photo-gallery {
    display: grid;
    grid-template-columns: 2fr 1fr;
    grid-template-rows: 250px 250px;
    gap: 15px;
    margin-bottom: 40px;
}

.main-img {
    grid-row: span 2;
    background-size: cover;
    background-position: center;
    border-radius: var(--radius);
}

.side-img {
    background-size: cover;
    background-position: center;
    border-radius: var(--radius);
}

/* Layout Split: Description vs Sidebar */
.villa-layout {
    display: grid;
    grid-template-columns: 1.8fr 1fr;
    gap: 60px;
}

.amenities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.amenity-item {
    background: white;
    padding: 20px;
    border-radius: 15px;
    text-align: center;
    font-size: 0.85rem;
    box-shadow: var(--shadow);
}

.booking-card {
    background: white;
    padding: 30px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    position: sticky;
    top: 120px; /* Sticks when scrolling */
    height: fit-content;
}

@media (max-width: 900px) {
    .villa-layout { grid-template-columns: 1fr; }
    .photo-gallery { grid-template-columns: 1fr; }
    .booking-card { position: static; margin-top: 40px; }
}

/* --- Island Template Styles --- */

.island-hero {
    height: 60vh;
    border-radius: var(--radius);
    margin: 20px;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.island-hero img {
    position: absolute;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -1;
}

/* Feature Grid: "Why this island?" */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin: 40px 0;
}

.feature-box {
    background: var(--white);
    padding: 30px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    text-align: left;
}

.feature-box h4 {
    color: var(--primary);
    margin-bottom: 10px;
    font-size: 1.2rem;
}

/* Travel Tips Section */
.tips-container {
    background: #f0f4f5; /* Very light teal-grey */
    padding: 40px;
    border-radius: var(--radius);
    display: flex;
    gap: 40px;
    margin-top: 60px;
}

.tip-card {
    flex: 1;
}

.tip-card h5 {
    font-family: 'Urbanist', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
    color: var(--accent);
}

@media (max-width: 800px) {
    .feature-grid { grid-template-columns: 1fr; }
    .tips-container { flex-direction: column; }
}