/* Rioga interaction layer: icon hovers, buttons, cards, form states.
   Loaded after style.css so it survives Tailwind rebuilds. */

/* ---- Icons (every Lucide icon on the site) ---- */
svg.lucide { transition: transform .4s cubic-bezier(.34,1.56,.64,1), filter .3s ease, color .3s ease; transform-origin: center; }
a:hover > svg.lucide,
button:hover > svg.lucide,
li:hover > svg.lucide,
span:hover > svg.lucide,
svg.lucide:hover { transform: translateY(-2px) scale(1.18) rotate(-6deg); filter: drop-shadow(0 4px 6px rgba(212,175,55,.4)); }

/* Circular icon badge: fills gold on hover */
.icon-badge { --ib: #facc15; display: inline-flex; align-items: center; justify-content: center; width: 2.75rem; height: 2.75rem; border-radius: 9999px;
  color: var(--ib); background: color-mix(in srgb, var(--ib) 12%, transparent); border: 1px solid color-mix(in srgb, var(--ib) 38%, transparent);
  transition: background-color .3s ease, color .3s ease, translate .35s cubic-bezier(.34,1.56,.64,1), box-shadow .3s ease; }
.icon-badge--sm { --ib: #D4AF37; width: 2.5rem; height: 2.5rem; }
.icon-badge:hover, .contact-row:hover .icon-badge { background: var(--ib); color: #0F3D2E; translate: 0 -3px; box-shadow: 0 0 0 6px color-mix(in srgb, var(--ib) 22%, transparent); }
.icon-badge:hover svg.lucide, .contact-row:hover .icon-badge svg.lucide { transform: scale(1.12) rotate(-8deg); filter: none; }
.contact-row { transition: translate .3s ease; }
.contact-row:hover { translate: 4px 0; }

/* ---- Buttons ---- */
.btn-primary, .btn-secondary { position: relative; overflow: hidden; isolation: isolate; }
.btn-primary::before { content: ""; position: absolute; inset: 0; z-index: -1; transform: translateX(-120%); transition: transform .7s ease;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.28) 50%, transparent 70%); }
.btn-primary:hover::before { transform: translateX(120%); }
.btn-primary:hover, .btn-secondary:hover { translate: 0 -2px; }
.btn-primary:active, .btn-secondary:active { translate: 0 0; }
.btn-icon { width: 1.1rem; height: 1.1rem; margin-left: .6rem; }
.btn-primary:hover .btn-icon { transform: translate(3px,-3px) rotate(0); filter: none; }
.btn-spinner { display: none; width: 1.1rem; height: 1.1rem; margin-left: .6rem; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: rg-spin .7s linear infinite; }
.btn-primary.is-loading { pointer-events: none; opacity: .85; }
.btn-primary.is-loading .btn-icon { display: none; }
.btn-primary.is-loading .btn-spinner { display: inline-block; }

/* ---- Navigation and footer links ---- */
.nav-link { position: relative; }
.nav-link::after { content: ""; position: absolute; left: 50%; bottom: 2px; width: 0; height: 2px; border-radius: 2px; background: #7A8B56; transition: width .3s ease, left .3s ease; }
.nav-link:hover::after { width: calc(100% - 1.5rem); left: .75rem; }
footer li > a[href] { display: inline-block; transition: color .3s ease, translate .3s ease; }
footer li > a[href]:hover { translate: 4px 0; }

/* ---- Cards ---- */
.luxury-card { transition: translate .5s cubic-bezier(.22,1,.36,1), box-shadow .5s ease; }
.luxury-card:hover { translate: 0 -6px; box-shadow: 0 25px 50px -12px rgba(15,61,46,.2); }
.luxury-card img { transition: transform .9s cubic-bezier(.22,1,.36,1); }
.luxury-card:hover img { transform: scale(1.06); }

/* ---- Contact form ---- */
#contact-form input, #contact-form select, #contact-form textarea { transition: border-color .25s ease, box-shadow .25s ease; }
#contact-form input:hover, #contact-form select:hover, #contact-form textarea:hover { border-color: #b9c4a3; }
#contact-form input:focus, #contact-form select:focus, #contact-form textarea:focus { border-color: #7A8B56; box-shadow: 0 0 0 4px rgba(122,139,86,.18); }
#contact-form :is(input, textarea):user-invalid { border-color: #dc2626; box-shadow: 0 0 0 4px rgba(220,38,38,.1); }
.hp-field { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-alert { border-radius: .75rem; padding: .9rem 1.1rem; margin-bottom: 1.25rem; font-size: .9rem; animation: rg-drop .4s ease both; }
.form-alert--error { background: #fef2f2; border: 1px solid #fecaca; color: #991b1b; }
.form-alert ul { margin: 0; padding-left: 1.1rem; list-style: disc; }

/* Success state with a drawn checkmark */
.form-success { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; min-height: 26rem; gap: .75rem; }
.form-success[hidden] { display: none; }
.check-circle { width: 5.5rem; height: 5.5rem; margin-bottom: .5rem; }
.check-circle circle { fill: none; stroke: #7A8B56; stroke-width: 2.5; stroke-dasharray: 160; stroke-dashoffset: 160; animation: rg-draw .7s ease forwards; }
.check-circle path { fill: none; stroke: #0F3D2E; stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 48; stroke-dashoffset: 48; animation: rg-draw .4s .6s ease forwards; }
.form-success h3, .form-success p, .form-success a { animation: rg-drop .6s .9s ease both; }

/* ---- Keyframes and accessibility ---- */
@keyframes rg-spin { to { transform: rotate(360deg); } }
@keyframes rg-draw { to { stroke-dashoffset: 0; } }
@keyframes rg-drop { from { opacity: 0; translate: 0 -8px; } to { opacity: 1; translate: 0 0; } }
:focus-visible { outline: 2px solid #D4AF37; outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; translate: none !important; }
}
