{
  "$schema": "https://schemas.wp.org/trunk/block.json",
  "apiVersion": 3,
  "name": "abb/countdown-alert",
  "title": "Countdown Alert (Pro)",
  "description": "An urgency banner with a live countdown — fixed date or per-visitor evergreen timers.",
  "category": "alert-box-blocks",
  "version": "1.0.0",
  "keywords": [
    "countdown",
    "timer",
    "sale",
    "deadline",
    "urgency",
    "launch",
    "offer"
  ],
  "textdomain": "alert-box-block",
  "attributes": {
    "theme": {
      "type": "string",
      "default": "tiles"
    },
    "layout": {
      "type": "string",
      "default": "banner"
    },
    "timerId": {
      "type": "string",
      "default": ""
    },
    "content": {
      "type": "object",
      "default": {
        "showEyebrow": true,
        "eyebrow": "Limited offer",
        "title": "The Summer Sale ends soon",
        "message": "Save 40% on every plan. When the clock hits zero, the deal is gone for good.",
        "showButton": true,
        "buttonText": "Claim the deal",
        "buttonUrl": "#",
        "buttonNewTab": false,
        "expiredMessage": "This offer has ended. Stay tuned — the next one is around the corner!"
      }
    },
    "timer": {
      "type": "object",
      "default": {
        "mode": "fixed",
        "endDate": "",
        "durationDays": 2,
        "durationHours": 0,
        "durationMinutes": 0,
        "restartHours": 0,
        "units": {
          "days": true,
          "hours": true,
          "minutes": true,
          "seconds": true
        },
        "showLabels": true,
        "labels": {
          "days": "",
          "hours": "",
          "minutes": "",
          "seconds": ""
        },
        "separator": "colon"
      }
    },
    "expire": {
      "type": "object",
      "default": {
        "action": "message",
        "hideButton": true
      }
    },
    "section": {
      "type": "object",
      "default": {
        "background": {
          "type": "gradient",
          "gradient": "radial-gradient(130% 150% at 0% 0%, #eef2ff 0%, #ffffff 46%, #fdf4ff 100%)"
        },
        "textColor": "#1e1b4b",
        "accent": "#6366f1",
        "padding": {
          "desktop": {
            "top": "32px",
            "right": "36px",
            "bottom": "32px",
            "left": "36px"
          },
          "tablet": {
            "top": "26px",
            "right": "28px",
            "bottom": "26px",
            "left": "28px"
          },
          "mobile": {
            "top": "18px",
            "right": "18px",
            "bottom": "18px",
            "left": "18px"
          }
        },
        "margin": {
          "desktop": {
            "top": "0px",
            "right": "0px",
            "bottom": "0px",
            "left": "0px"
          },
          "tablet": {
            "top": "0px",
            "right": "0px",
            "bottom": "0px",
            "left": "0px"
          },
          "mobile": {
            "top": "0px",
            "right": "0px",
            "bottom": "0px",
            "left": "0px"
          }
        },
        "radius": {
          "desktop": {
            "top": "20px",
            "right": "20px",
            "bottom": "20px",
            "left": "20px"
          },
          "tablet": {
            "top": "",
            "right": "",
            "bottom": "",
            "left": ""
          },
          "mobile": {
            "top": "",
            "right": "",
            "bottom": "",
            "left": ""
          }
        },
        "border": {
          "width": "1px",
          "style": "solid",
          "color": "rgba(99, 102, 241, 0.16)"
        },
        "shadow": [
          {
            "hOffset": "0px",
            "vOffset": "24px",
            "blur": "48px",
            "spreed": "-28px",
            "color": "rgba(15, 23, 42, 0.35)",
            "isInset": false
          }
        ]
      }
    },
    "eyebrow": {
      "type": "object",
      "default": {
        "typo": {
          "fontSize": {
            "desktop": "11.5px",
            "tablet": null,
            "mobile": null
          },
          "fontWeight": 800,
          "fontVariant": "800",
          "lineHeight": "1.2",
          "letterSpace": "0.14em",
          "textTransform": "uppercase"
        },
        "colors": {
          "color": "#6366f1",
          "bg": "rgba(99, 102, 241, 0.14)"
        }
      }
    },
    "title": {
      "type": "object",
      "default": {
        "typo": {
          "fontSize": {
            "desktop": "28px",
            "tablet": "24px",
            "mobile": "20px"
          },
          "fontWeight": 800,
          "fontVariant": "800",
          "lineHeight": "1.2",
          "letterSpace": "-0.015em"
        },
        "color": "#1e1b4b"
      }
    },
    "message": {
      "type": "object",
      "default": {
        "typo": {
          "fontSize": {
            "desktop": "15.5px",
            "tablet": null,
            "mobile": "14.5px"
          },
          "lineHeight": "1.6"
        },
        "color": "rgba(30, 27, 75, 0.74)"
      }
    },
    "digits": {
      "type": "object",
      "default": {
        "typo": {
          "fontSize": {
            "desktop": "40px",
            "tablet": null,
            "mobile": null
          },
          "fontWeight": 800,
          "fontVariant": "800"
        },
        "tileSize": {
          "desktop": "",
          "tablet": null,
          "mobile": null
        },
        "gap": {
          "desktop": "12px",
          "tablet": "10px",
          "mobile": "6px"
        },
        "colors": {
          "color": "#ffffff",
          "bgType": "gradient",
          "bg": "",
          "gradient": "linear-gradient(165deg, #8f91f5 0%, #6366f1 48%, #494bb2 100%)"
        },
        "radius": "14px",
        "shadow": [
          {
            "hOffset": "0px",
            "vOffset": "4px",
            "blur": "0px",
            "spreed": "0px",
            "color": "#363885",
            "isInset": false
          },
          {
            "hOffset": "0px",
            "vOffset": "16px",
            "blur": "26px",
            "spreed": "-10px",
            "color": "rgba(99, 102, 241, 0.7)",
            "isInset": false
          },
          {
            "hOffset": "0px",
            "vOffset": "1px",
            "blur": "0px",
            "spreed": "0px",
            "color": "rgba(255, 255, 255, 0.35)",
            "isInset": true
          }
        ],
        "sepColor": "#6366f1",
        "trackColor": ""
      }
    },
    "label": {
      "type": "object",
      "default": {
        "typo": {
          "fontSize": {
            "desktop": null,
            "tablet": null,
            "mobile": null
          },
          "fontWeight": 700,
          "fontVariant": "700",
          "lineHeight": "1.1",
          "letterSpace": "0.12em",
          "textTransform": "uppercase"
        },
        "color": "rgba(30, 27, 75, 0.74)"
      }
    },
    "button": {
      "type": "object",
      "default": {
        "typo": {
          "fontSize": {
            "desktop": "15px",
            "tablet": null,
            "mobile": null
          },
          "fontWeight": 700,
          "fontVariant": "700",
          "lineHeight": "1.2"
        },
        "colors": {
          "color": "#ffffff",
          "bg": "#1e1b4b"
        },
        "hoverColors": {
          "color": "#ffffff",
          "bg": "#1e1b4b"
        },
        "padding": {
          "desktop": {
            "top": "13px",
            "right": "22px",
            "bottom": "13px",
            "left": "22px"
          },
          "tablet": {
            "top": "13px",
            "right": "22px",
            "bottom": "13px",
            "left": "22px"
          },
          "mobile": {
            "top": "13px",
            "right": "22px",
            "bottom": "13px",
            "left": "22px"
          }
        },
        "radius": "999px",
        "shadow": [
          {
            "hOffset": "0px",
            "vOffset": "12px",
            "blur": "24px",
            "spreed": "-12px",
            "color": "rgba(30, 27, 75, 0.7)",
            "isInset": false
          }
        ]
      }
    },
    "expired": {
      "type": "object",
      "default": {
        "typo": {
          "fontSize": {
            "desktop": "15px",
            "tablet": null,
            "mobile": null
          },
          "fontWeight": 600,
          "fontVariant": "600",
          "lineHeight": "1.5"
        },
        "colors": {
          "color": "#1e1b4b",
          "bg": "rgba(99, 102, 241, 0.12)"
        }
      }
    }
  },
  "supports": {
    "align": [
      "wide",
      "full"
    ],
    "anchor": true,
    "html": false
  },
  "example": {
    "attributes": {
      "theme": "tiles",
      "layout": "banner",
      "timer": {
        "mode": "evergreen",
        "endDate": "",
        "durationDays": 2,
        "durationHours": 14,
        "durationMinutes": 37,
        "restartHours": 0,
        "units": {
          "days": true,
          "hours": true,
          "minutes": true,
          "seconds": true
        },
        "showLabels": true,
        "labels": {
          "days": "",
          "hours": "",
          "minutes": "",
          "seconds": ""
        },
        "separator": "colon"
      },
      "content": {
        "showEyebrow": true,
        "eyebrow": "Limited offer",
        "title": "Black Friday starts now",
        "message": "Up to 60% off everything — only while the timer runs.",
        "showButton": true,
        "buttonText": "Claim the deal",
        "buttonUrl": "#",
        "buttonNewTab": false,
        "expiredMessage": "This offer has ended. Stay tuned — the next one is around the corner!"
      }
    }
  },
  "editorScript": "file:./index.js",
  "editorStyle": "file:./index.css",
  "style": "file:./view.css",
  "viewScript": "file:./view.js",
  "render": "file:./render.php"
}