/* ===================================================================
   Paidin Tailwind Overrides
   Design tokens, gradients and animations that Tailwind CDN
   cannot express as inline utilities.
   =================================================================== */

:root {
    --pi-green: #77C043;
    --pi-green-dark: #65a838;
    --pi-gray: #4F4E4F;
    --pi-blue: #3B82F6;
    --pi-amber: #D97706;
}

/* --- Page-level gradient background -------------------------------- */
.pi-page-gradient {
    background:
        radial-gradient(ellipse 80% 60% at 10% 20%, rgba(119, 192, 67, .06) 0%, transparent 60%),
        radial-gradient(ellipse 60% 50% at 90% 80%, rgba(217, 119, 6, .04) 0%, transparent 60%),
        #f9fafb;
}

/* --- Hero card gradient ------------------------------------------- */
.pi-hero-gradient {
    background:
        radial-gradient(ellipse 70% 55% at 20% 30%, rgba(119, 192, 67, .08) 0%, transparent 55%),
        radial-gradient(ellipse 50% 40% at 80% 70%, rgba(217, 119, 6, .05) 0%, transparent 55%),
        linear-gradient(145deg, #ffffff 0%, #f9fafb 100%);
}

/* --- Slide-in mobile menu ----------------------------------------- */
.pi-mobile-menu {
    transform: translateX(100%);
    transition: transform .3s cubic-bezier(.4, 0, .2, 1);
}

.pi-mobile-menu.open {
    transform: translateX(0);
}

.pi-mobile-backdrop {
    opacity: 0;
    pointer-events: none;
    transition: opacity .3s cubic-bezier(.4, 0, .2, 1);
}

.pi-mobile-backdrop.open {
    opacity: 1;
    pointer-events: auto;
}

/* --- Green accent top for USP cards ------------------------------- */
.pi-accent-top {
    position: relative;
}

.pi-accent-top::before {
    content: '';
    position: absolute;
    top: 0;
    left: 24px;
    right: 24px;
    height: 3px;
    border-radius: 0 0 3px 3px;
    background: var(--pi-green);
}

/* --- Input focus with brand color --------------------------------- */
input:focus,
textarea:focus {
    outline: none;
    border-color: rgba(119, 192, 67, .85) !important;
    box-shadow: 0 0 0 3px rgba(119, 192, 67, .18) !important;
}

/* --- Honeypot field (contact form) -------------------------------- */
.pi-hp {
    position: absolute;
    left: -9999px;
    top: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
}

/* --- Prose adjustments for legal pages ---------------------------- */
.pi-prose h2 {
    margin-top: 1.5em;
    margin-bottom: 0.5em;
    font-size: 1.25rem;
    font-weight: 700;
    color: #111827;
}

.pi-prose h3 {
    margin-top: 1em;
    margin-bottom: 0.4em;
    font-size: 1.1rem;
    font-weight: 600;
    color: #111827;
}

.pi-prose p {
    margin-top: 0.4em;
    margin-bottom: 0.8em;
    line-height: 1.7;
    color: #374151;
}

.pi-prose ul {
    margin: 0.5em 0;
    padding-left: 1.25em;
}

.pi-prose li {
    margin: 0.35em 0;
    line-height: 1.7;
    color: #374151;
}

.pi-prose a {
    color: var(--pi-green-dark);
    text-decoration: underline;
}

.pi-prose a:hover {
    color: var(--pi-green);
}

/* --- USP card hover -------------------------------------------------- */
.pi-usp-card {
    background: white;
    border: 1px solid #e5e7eb;
    transition: transform .2s ease, box-shadow .2s ease;
}

.pi-usp-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, .08);
}

/* --- Button background overrides (defeat Tailwind CDN preflight) ----- */
/* Tailwind CDN preflight sets  button { background-color: transparent }
   which can override utility classes. These !important rules guarantee
   correct backgrounds on all action buttons.                              */

/* Green CTA */
.bg-pi-green {
    background-color: #77C043 !important;
}
button.bg-pi-green,
a.bg-pi-green {
    color: #ffffff !important;
}
.hover\:bg-pi-green-dark:hover {
    background-color: #65a838 !important;
}

/* Blue (invoice / document actions) */
.bg-blue-500 {
    background-color: #3B82F6 !important;
}
button.bg-blue-500,
a.bg-blue-500 {
    color: #ffffff !important;
}
.hover\:bg-blue-600:hover {
    background-color: #2563EB !important;
}

/* Red (destructive) */
.bg-red-600 {
    background-color: #DC2626 !important;
}
button.bg-red-600,
a.bg-red-600 {
    color: #ffffff !important;
}
.hover\:bg-red-700:hover {
    background-color: #B91C1C !important;
}

/* Gray ghost buttons - ensure border and text show */
.border-gray-300 {
    border-color: #d1d5db !important;
}
.text-gray-600 {
    color: #4b5563 !important;
}

/* Amber (attention) */
.bg-amber-600 {
    background-color: #D97706 !important;
}

/* --- Nyhet badge (id.tic.io-inspired) -------------------------------- */
.pi-badge-nyhet {
    position: absolute;
    top: -10px;
    left: 20px;
    background: var(--pi-green);
    color: white;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    padding: 2px 10px;
    border-radius: 999px;
    text-transform: uppercase;
}
